PHP call_user_func vs. funkcja wywołująca
Jestem pewien, że jest to bardzo łatwe wyjaśnienie. Jaka jest różnica między tym:
function barber($type){
echo "You wanted a $type haircut, no problem\n";
}
call_user_func('barber', "mushroom");
call_user_func('barber', "shave");
... i to (i jakie są korzyści?):
function barber($type){
echo "You wanted a $type haircut, no problem\n";
}
barber('mushroom');
barber('shave');