Re: indirect function call

From: Date: Wed, 14 Feb 2001 16:20:08 +0000
Subject: Re: indirect function call
References: 1  Groups: php.pear 
Request: Send a blank email to php-pear+get-1345@lists.php.net to get a copy of this message
Try the following last 3 lines instead: $foo = new bdd; $bar = "bdd_function"; $foo->$bar("foo bar !"); On Wed, 14 Feb 2001, Burak DAYIOGLU wrote: > Hi, > We are having a little problem with indirect function calls as being > discussed on the list for a while... The below thingie does not work, > does anybody have any idea to make it run? > > regards, > -bd > > <?php > > class bdd > { > var $bdd_var; > function bdd_function($input) > { > echo "This is bdd_function speaking and the input is : > $input"; > } > } > > $foo = new bdd; > $bar = $foo->bdd_function; > $bar("foo bar !"); > ?> > > -- John Donagher Application Engineer Intacct Corp. - Powerful Accounting on the Web 408-395-0989 720 University Ave. Los Gatos CA 95032 www.intacct.com Public key available off http://www.keyserver.net Key fingerprint = 4024 DF50 56EE 19A3 258A D628 22DE AD56 EEBE 8DDD

« previous php.pear (#1345) next »