Re: DOMXML Warning

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, February 13, 2008 1:51 am, Miguel J. Jiménez wrote:
> Hi, after enabling error reporting with E_ALL I am having this strange
> warning while loading a XML:
>
> Warning: DOMDocument::load() [function.DOMDocument-load]: Extra
> content
> at the end of the document in [...]
>
> The code I use is:
>
> $dom = new DOMDocument();
> $dom->load("http://example.com/file.xml";);
> [...]
>
> If I open the xml uri (with firefox) I get a complete and well formed
> xml (nothing strange about it).
>
> With error reporting disabled everything works fine so I am
> puzzled :-( Any help will be appreciated.

Open the document in a Hex editor to see if there are unprintable
characters at the end.

It's also possible that they aren't at the END of the document, but at
the END of some node within the document, or even some CDATA within a
node within the document...

You could probably Google for an XML validator that would perhaps be
more specific about what's wrong where.

-- 
Some people have a "gift" link here.
Know what I want?
I want you to buy a CD from some indie artist.
http://cdbaby.com/from/lynch
Yeah, I get a buck. So?

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux