1
0
mirror of https://github.com/e107inc/e107.git synced 2025-07-31 11:50:30 +02:00

Extra debug option for tracking XML issues.

This commit is contained in:
Cameron
2016-10-28 09:09:47 -07:00
parent f3412a4e89
commit 52b473dd33

View File

@@ -95,6 +95,12 @@ class parseXml extends xmlClass // BC with v1.x
{
$error = sprintf('XML error: %s at line %d, column %d', xml_error_string(xml_get_error_code($this->parser)), xml_get_current_line_number($this->parser),xml_get_current_column_number($this->parser));
$log->addDebug($error)->save('XML');
if(e_DEBUG === true)
{
$error .= "\n".$data;
$error .= "\n--------------------------------------------\n\n";
$log->addDebug($error)->toFile('xmlErrors',"XML Error Log",true);
}
return FALSE;
}
}