From 4262e0019a519b2db4d6507ff0f2984ac1c6249a Mon Sep 17 00:00:00 2001 From: zaikos Date: Fri, 26 Dec 2014 14:43:38 -0500 Subject: [PATCH] Temporarily disable entity loader when importing XML file. --- plugins/import_export/init.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/plugins/import_export/init.php b/plugins/import_export/init.php index d185210e..e61b62b6 100644 --- a/plugins/import_export/init.php +++ b/plugins/import_export/init.php @@ -189,6 +189,8 @@ class Import_Export extends Plugin implements IHandler { $num_processed = 0; $num_feeds_created = 0; + libxml_disable_entity_loader(false); + $doc = @DOMDocument::load($filename); if (!$doc) { @@ -206,6 +208,8 @@ class Import_Export extends Plugin implements IHandler { $doc = DOMDocument::loadXML($data); } + libxml_disable_entity_loader(true); + if ($doc) { $xpath = new DOMXpath($doc); -- 2.39.5