Dang lack of a list reply button

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I have only done this when I am building the function name using a
string expression, so my advice might not be necessary in your case but
it has worked for me:

{$function}($var);

In that case, the curly braces equate to the eval() function in
Javascript.

Jay Blanchard wrote:
> I don't think you can put a function name in a variable and call it
like
> $function($var).

Yes you can - it's basically the same as variable variables.

-Stut

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux