|
Posted by Ramon on 09/28/73 11:27
I'm sorry, I don't quite understand what you are asking...
If you are asking how to use results of a function in another function
then you should do this.
function test1()
{
return "Hello World!";
}
function test2($string)
{
}
test2(test1());
or
$moo = test1();
test2($moo);
Will output *Hello World!*
*****************
If you are asking how you can execute a function inside another
function, then thats exactly what you do... just call it in the code.
Hope it helps, if not try reading the PHP manual under the
functions/syntax section.
Cheers,
D
_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.
>
>
[Back to original message]
|