Commit 48b8953c authored by Ben Bradshaw's avatar Ben Bradshaw
Browse files

[#3347] Patching XML Feed Reader 1.0.3 - adding $suppressWarnings fix

previous commit with this fix: 6c29487b
parent 43c907e6
......@@ -86,8 +86,13 @@ class XML_Feed_Parser implements Iterator
*/
function __construct($feed, $strict = false, $suppressWarnings = false, $tidy = false)
{
$options = 0;
if ($suppressWarnings) {
$options |= LIBXML_NOWARNING;
$options |= LIBXML_NOERROR;
}
$this->model = new DOMDocument;
if (! $this->model->loadXML($feed)) {
if (! $this->model->loadXML($feed, $options)) {
if (extension_loaded('tidy') && $tidy) {
$tidy = new tidy;
$tidy->parseString($feed,
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment