A error handler's configuration is determined by the arguments used in
its construction. Here's an overview of these parameters.
-
<?php
-
require_once 'HTML/CSS.php';
-
-
$errorConf = array('error_handler' => 'myErrorHandler',
-
'push_callback' => 'myError',
-
// ... more options
-
);
-
$css = new
HTML_CSS(null,
$errorConf);
-
?>
Table 10.1. Error Handler configuration parameters
Option
|
Type
|
Description
|
error_handler
|
callback
|
A valid callback (function) to manage errors raised by the
HTML_CSS::raiseError() method.
Default is: HTML_CSS::_errorHandler
|
push_callback
|
callback
|
A valid callback (function) that decides to following action.
Default return: PEAR_ERROR_DIE if
exception, NULL otherwise.
|
error_callback
|
callback
|
A valid callback (function) that decides to call a real free
user function. Default call: none
|
message_callback
|
callback
|
A valid callback (function) to control message generation.
Default is: HTML_CSS_Error::_msgCallback
|
context_callback
|
callback
|
A valid callback (function) to control error context
generation. Default is: HTML_CSS_Error::getBacktrace
|
handler
|
mixed
|
any handler-specific settings
|