So I have a PHP Script thats parsing an XML Response from Google Analytics. It has been working for a few weeks, but today I've been getting this warning, and simple xml load string is not converting the xml response into a simplexml object.
Message: simplexml_load_string(): Entity: line 743: parser error : Entity 'acirc' not defined
I have tried utf8_encoding the response before I pass it into simplexml_load_string, but it isn't working. I believe that acirc is an encoded symbol, and that this symbol is screwing up the parser somehow?
I get the warning above twice, and then I get this one twice also:
Message: simplexml_load_string(): Entity: line 743: parser error : Entity 'cent' not defined
Any advice would be a huge help, thanks!
Thanks for the comment Marc, I have tried this:
$xml = simplexml_load_string(htmlspecialchars_decode($response_body));
And I get an interesting error, but the xml object is still empty:
Entity: line 743: parser error : Input is not proper UTF-8, indicate encoding ! Bytes: 0x84 0x26 0x63 0x65
'"<>&). Anything else is invalid XML, which is basically ALL of the HTML character entities. - Marc B