1 system_test.module | _system_test_second_shutdown_function($arg1, $arg2) |
Dummy shutdown function.
File
- core/
modules/ simpletest/ tests/ system_test.module, line 443 - Test module for system functions.
Code
function _system_test_second_shutdown_function($arg1, $arg2) {
// The page has already been printed, so we are unable to affect its output.
// Print something (which won't show up).
$output = format_string('Second shutdown function, arg1 : @arg1, arg2: @arg2', array('@arg1' => $arg1, '@arg2' => $arg2));
print $output;
watchdog('shutdown', $output);
// Throw an exception with an HTML tag. Since this is called in a shutdown
// function, it will not bubble up to the default exception handler but will
// be caught in _backdrop_shutdown_function() and be displayed through
// _backdrop_render_exception_safe().
throw new Exception('Backdrop is <blink>awesome</blink>.');
}