|
@@ -34,12 +34,12 @@ if (ini_get('docref_root')=='') ini_set('docref_root','http://www.php.net/');
|
|
class ErrorHandler {
|
|
class ErrorHandler {
|
|
|
|
|
|
/**
|
|
/**
|
|
- * Constructor
|
|
|
|
|
|
+ * Constructor (PHP5 style, required in some future version of PHP)
|
|
* @param object $oTemplate Template object
|
|
* @param object $oTemplate Template object
|
|
* @param string $sTemplateFile Template containing the error template
|
|
* @param string $sTemplateFile Template containing the error template
|
|
* @since 1.5.1
|
|
* @since 1.5.1
|
|
*/
|
|
*/
|
|
- function ErrorHandler(&$oTemplate, $sTemplateFile) {
|
|
|
|
|
|
+ function __construct(&$oTemplate, $sTemplateFile) {
|
|
# echo 'init error handler...';
|
|
# echo 'init error handler...';
|
|
$this->TemplateName = $sTemplateFile;
|
|
$this->TemplateName = $sTemplateFile;
|
|
$this->Template =& $oTemplate;
|
|
$this->Template =& $oTemplate;
|
|
@@ -49,6 +49,16 @@ class ErrorHandler {
|
|
$this->Template->assign('delayed_errors', $this->delayed_errors);
|
|
$this->Template->assign('delayed_errors', $this->delayed_errors);
|
|
}
|
|
}
|
|
|
|
|
|
|
|
+ /**
|
|
|
|
+ * Constructor (PHP4 style, kept for compatibility reasons)
|
|
|
|
+ * @param object $oTemplate Template object
|
|
|
|
+ * @param string $sTemplateFile Template containing the error template
|
|
|
|
+ * @since 1.5.1
|
|
|
|
+ */
|
|
|
|
+ function ErrorHandler(&$oTemplate, $sTemplateFile) {
|
|
|
|
+ self::__construct($oTemplate, $sTemplateFile);
|
|
|
|
+ }
|
|
|
|
+
|
|
/**
|
|
/**
|
|
* Sets the error template
|
|
* Sets the error template
|
|
* @since 1.5.1
|
|
* @since 1.5.1
|