[Expat-discuss] I need help with error message 'xml declaration not at start of external entity'

Steve Fogoros sfogoros at hsc.unt.edu
Fri Jun 20 19:02:04 CEST 2008


Hello,
 
I'm using the PHP module XML Parser under PHP version 4.4.0.
 
I get the referenced error due to new lines before the preamble.
 
I've searched the error message and reviewed the w3c spec for
information on xml parsing. I haven't found anything that explicitly
states what a parser should do about leading white space outside of the
xml document. I've also noted that there are many failures of this type
reported on WordPress and RSS feed forums. In all cases, the correction
seems to be altering the provider application to submit the xml document
without any leading characters before the preamble.
 
My question is: does the xml spec explicitly specify that there be
nothing other than the preamble at the beginning of a well formed xml
doc? Is this something that shoud/could be addressed in the parser (it
sure would eliminate a lot of failed implementations)?
 
Thanks, Steve
 



** Confidentiality Notice: This e-mail and any files transmitted with it are confidential to the extent permitted by law and intended solely for the use of the individual or entity to whom they are addressed. If you have received this e-mail in error please notify the originator of the message and destroy all copies. **


More information about the Expat-discuss mailing list