Jump to content

Archived

This topic is now archived and is closed to further replies.

joeyjgarcia

PHP XML parsing?

Recommended Posts

I must be missing something but I've been looking at PHP XML tutorials and manuals for hours and I just don't see how they get the data from between the tags. Every tutorial shows how to capture the tag name and the attribute values but none are showing how to capture the data between tags, e.g., <customer>John Doe</customer>; how do I get to "John Doe"?

Share this post


Link to post
Share on other sites
When parsing XML, I personally have used the xml_parse_into_struct() function. Look it up in the manual, there are a couple of examples of how you can use it.

Share this post


Link to post
Share on other sites

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.