Page 1 of 1

Parse XML from URL PHP4

Posted: Thu Apr 20, 2006 6:18 am
by javi_arboleya
Hi,

I would like to know what's the best way to parse a xml document directly from a url.

My problem is that I need to access a url and get the xml document that gives me, and then parse it in order to get a code.

How would I do this?

thanks in advance

Posted: Thu Apr 20, 2006 11:02 am
by feyd
file_get_contents() or similar the page data and call xml_parse() I believe.

Posted: Thu Apr 20, 2006 1:04 pm
by timvw
There is a parse_into_struct or parse_into_array function if you don't want to parse it yourself....