Altova Mailing List Archives>Archive Index >comp.text.xml Archive Home >Recent entries [Thread Prev] >Thread Next - Re: Parsing an XML file with namespace Parsing an XML file with namespaceTo: NULL Date: 9/21/2008 12:27:00 PM I am new to XML but have managed to parse most of the XML files I have come across within my javascript scripts. Until now. I am trying to parse the currency file available free from http://www.ecb.int/stats/eurofxref/eurofxref-daily.xml The file looks like this: <gesmes:Envelope> <gesmes:subject>Reference rates</gesmes:subject> <gesmes:Sender> <gesmes:name>European Central Bank</gesmes:name> </gesmes:Sender> <Cube> <Cube time="2008-09-19"> <Cube currency="USD" rate="1.4236"/> <Cube currency="JPY" rate="153.03"/> ....... <Cube currency="THB" rate="48.630"/> <Cube currency="ZAR" rate="11.4902"/> </Cube> </Cube> </gesmes:Envelope> I can parse the gesmes:subject and gesmes:name but I have no idea how to parse the <Cube> data, which is of course what I want. I have Googled around and this leads me to believe that this is a namespace issue but I cannot find out how to parse this within Javacript or if necessary PHP Any help would be greatly appreciated, Steve. | ||||||
| Company | Legal | Press | Partners | Careers | Sitemap | Contact Us | Altova Blog | Mobile | Full Site | |||
|
