|   | php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login | 
| 
 PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits              [2007-11-13 23:50 UTC] stas@php.net
  [2007-11-14 01:27 UTC] johannes@php.net
 | |||||||||||||||||||||||||||
|  Copyright © 2001-2025 The PHP Group All rights reserved. | Last updated: Fri Oct 31 06:00:01 2025 UTC | 
Description: ------------ When call_user_func is given callback array with class name as string, it refuses to call non-static functions, even though PHP can call it with just E_STRICT. Reproduce code: --------------- <?php class Foo { function bar() { echo "OK!"; } } call_user_func(array("Foo", "bar"), 123); Foo::bar(123); Expected result: ---------------- OK!OK! Actual result: -------------- Warning: call_user_func() expects parameter 1 to be valid callback, array given in t.php on line 5 OK!