methods - PHP __callStatic failing intermittently -


i have simple __callstatic magic method defined in class:

public static function __callstatic($method, $args) {     if(substr($method, 0, 8) == "require_") {           // stuff     } } 

the script dies fatal error "undefined method myclass::require_foo" when executed.

however..

if modify file in way, example:

public static function __callstatic($method, $args) {     if(substr($method, 0, 8) == "require_") {           // hello     } } 

it works on next page load. subsequent page loads fail until make change file.

this creepy, right? 100% reproducible every time.

this problem related opcode caching on server. eaccelerator has known issues __callstatic(). https://eaccelerator.net/ticket/382


Comments

Popular posts from this blog

c# - SVN Error : "svnadmin: E205000: Too many arguments" -

c++ - Using OpenSSL in a multi-threaded application -

All overlapping substrings matching a java regex -