|
Posted by Chris Hope on 10/13/43 11:27
_andrea.l wrote:
> I'd like to write a function like:
>
> function f(){ ... bla ...}
> f_example(f);
>
> function f_example($function_to_execute)
> {...bla... $function_to_execute() ...bla....}
>
> AND how to pass the variable of the function :
>
> function f_example($function_to_execute($var1,$var2))
> {...bla... $function_to_execute() ...bla....}
>
> Thank you in advance for the time you'll spend for me,
> Andrea.
This should get you going in the right direction:
http://www.php.net/manual/en/function.call-user-func-array.php
--
Chris Hope | www.electrictoolbox.com | www.linuxcdmall.com
Navigation:
[Reply to this message]
|