not well-formed (invalid token) error
I keep getting this error that crashes my program:
not well-formed (invalid token) at line 1, column 1945, byte 2017 at /usr/local/lib/perl5/site_perl/5.8.7/i686-linux/XML/Parser.pm line 187
What does this error mean and is there a workaround? Looking at my log files, my initial impression is that the api chokes on special characters in html, and this in turn crashes the api.
Thanks for any help.
[428 byte] By [
Regent2] at [2008-2-24]
C'mon, guys. Someone else should be getting this error.
Using the API, try the following query:
link: http://www.kenexa.com
This always breaks my program due to this error, while similar queries for other domains run perfectly fine.
I'm getting the very same error....
"not well-formed (invalid token) at line 2, column 5, byte 6 at /usr/lib/perl5/XML/Parser.pm line 187"
When attempting to parse a HTML archive..... hopefully I can come up with some sort of solution. If I do I'll let you know, please do the same if you can solve it
I have found an explanation for the "invalid-token" error when trying to parse certain documents. The underlying principle is that the XML::Parser module does not accept certain characters in the text:
& (ampersand, must be encoded as
&)
< (left angle bracket, must be encoded as
<)
> (right angle bracket, must be encoded as
>)
Don't forget to include the semicolon!
For a more thorough explanation and also to get around the problem by using CDATA sections in your DTD, here it is the link to the answer: http://www.monkeybreadsoftware.de/listarchive-realbasic-nug/2006-04/thread-05_4.shtml
Regards,
Edu
is that speacial characater replacement needed only for POST method?
i have used '&' character in GET and it works fine for me, but while using it for POST i get the
same error..
and above all, i get the same error even after replacing & with &
any suggestions....