Re: call_user_*()
| From: | Sterling Hughes | Date: | Sun, 13 May 2001 14:58:34 +0000 |
| Subject: | Re: call_user_*() | ||
| References: | 1 2 3 4 | Groups: | php.dev |
| Request: | Send a blank email to php-dev+get-55084@lists.php.net to get a copy of this message | ||
Stefan Livieratos wrote:
"Sterling Hughes" <sterling@designmultimedia.com> schrieb im Newsbeitrag news:3AFE1D61.1070304@designmultimedia.com...Right, that was a brain fart, I corrected that in the above message. -SterlingbeWhereas, replacing the call_user_func above with the following: call_user_func($name, array($param1));Well, I thought that the function call_user_func_array() is supposed to'call_user_func_array'called this way. What good is it anyway? I suggestBut you said that 'call_user_func' can be also called like this:should be removed as it is not needed and also doesn't work with user functions that expect arguments by reference.Well it is needed... If you need to decide how many arguments to pass to a function at execution time then the call_user_func_array() function is critical.call_user_func($function_name, array($arg1, arg2, arg3));Where's the difference between call_user_func and call_user_func_array?