I performed two tests on the register_shutdown_function() to see under what conditions it was called, and if a can call a static method from a class. Here are the results:
<?php
class Shutdown
{
public static function Method ($mixed = 0)
{
$ap = dirname (__FILE__);
$mixed = time () . " - $mixed\n";
file_put_contents ("$ap/shutdown.log", $mixed, FILE_APPEND);
}
}
register_shutdown_function (array ('Shutdown', 'Method'), 'throw');
throw new Exception ('bla bla');
?>
To test simply leave one of the three test lines uncommented and execute. Executing bottom-up yielded:
1138382480 - 0
1138382503 - exit
1138382564 - throw
HTH