Earlier on I had a problem with namespaces for getting XML attributes. When I finally got that sorted, I ran into an even weirder problem when fetching elements using xpath. Again, it was just a tiny little detail.
posted on June 3, 2008 - 0 comment(s) - tags: xml, namespace, simplexml, xpath, php
I've so far worked only very little with XML with namespaces, especially in terms of parsing it. Therefor, I was quite stumped today on the parsing of a particular snippet of XML which contained an element that had an xlink:href attribute. I just couldn't get that attribute's value out. The solution, as often seems to be the case, is quite simple.
posted on May 30, 2008 - 1 comment(s) - tags: simplexml, xml, namespaces, php