neonet
Новичок
raiseError
Помогите разобраться пожалуйста, у меня такая проблема(
Unknown error: Declaration of XML_Parser::raiseError() should be compatible with that of PEAR::raiseError() in /home/nnn/data/www/nnnu/sys/pear/XML/Parser.php on line 634
File PEAR.php
File Parser.php
Не выкупаю.. что с чем не совместимо?
Помогите разобраться пожалуйста, у меня такая проблема(
Unknown error: Declaration of XML_Parser::raiseError() should be compatible with that of PEAR::raiseError() in /home/nnn/data/www/nnnu/sys/pear/XML/Parser.php on line 634
File PEAR.php
PHP:
function &raiseError($message = null,
$code = null,
$mode = null,
$options = null,
$userinfo = null,
$error_class = null,
$skipmsg = false)
{
// The error is yet a PEAR error object
if (is_object($message)) {
$code = $message->getCode();
$userinfo = $message->getUserInfo();
$error_class = $message->getType();
$message->error_message_prefix = '';
$message = $message->getMessage();
}
if (isset($this) && isset($this->_expected_errors) && sizeof($this->_expected_errors) > 0 && sizeof($exp = end($this->_expected_errors))) {
if ($exp[0] == "*" ||
(is_int(reset($exp)) && in_array($code, $exp)) ||
(is_string(reset($exp)) && in_array($message, $exp))) {
$mode = PEAR_ERROR_RETURN;
}
}
// No mode given, try global ones
if ($mode === null) {
// Class error handler
if (isset($this) && isset($this->_default_error_mode)) {
$mode = $this->_default_error_mode;
$options = $this->_default_error_options;
// Global error handler
} elseif (isset($GLOBALS['_PEAR_default_error_mode'])) {
$mode = $GLOBALS['_PEAR_default_error_mode'];
$options = $GLOBALS['_PEAR_default_error_options'];
}
}
if ($error_class !== null) {
$ec = $error_class;
} elseif (isset($this) && isset($this->_error_class)) {
$ec = $this->_error_class;
} else {
$ec = 'PEAR_Error';
}
if ($skipmsg) {
$a = new $ec($code, $mode, $options, $userinfo);
return $a;
} else {
$a = new $ec($message, $code, $mode, $options, $userinfo);
return $a;
}
}
PHP:
function raiseError($msg = null, $ecode = 0)
{
$msg = !is_null($msg) ? $msg : $this->parser;
$err = new XML_Parser_Error($msg, $ecode);
return parent::raiseError($err);
}
Не выкупаю.. что с чем не совместимо?