diff options
Diffstat (limited to 'it_xml.class')
-rw-r--r-- | it_xml.class | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/it_xml.class b/it_xml.class index 69754ff..a048b58 100644 --- a/it_xml.class +++ b/it_xml.class @@ -90,7 +90,7 @@ function from_xml($xmldata, $p) $xmldata = '<?xml version="1.0" encoding="' . $this->_p['encoding'] . '"?>' . $xmldata; # Decode illegal entities but protect semantically important ones - $xmldata = html_entity_decode(preg_replace('/&(amp|lt|gt|#38|#60|#62|#x26|#x3C|#x3E);/i', '&$1;', $xmldata), ENT_QUOTES, $this->_p['encoding']); + $xmldata = html_entity_decode(preg_replace('/&(amp|lt|gt|#38|#60|#62|#x26|#x3C|#x3E);/i', '&$1;', $xmldata), ENT_NOQUOTES, $this->_p['encoding']); # If should be utf-8 and can't be decoded as such, fix it, even if mixed between both if (!preg_match('/^<\?xml[^>]* encoding=/i', $xmldata) || preg_match('/^<\?xml[^>]* encoding=.UTF-8/i', $xmldata)) |