Skip to content
Advertisement

Tag: xml

How to retrieve an attribute from a namespaced element

I am trying to get the url attributes from the <media:content> elements in this RSS feed: Here’s what I have so far: This code works for all elements except the ones with a semicolon in the name, like <media:content> or <dc:contributor>. If I open the XML feed in my browser I can see the tag I am looking for: I

Alphabetize Petfinder API List

I’m using the Petfinder API for Wordpress plugin. The plugin defaults to listing animals based on how old the Petfinder entries are, from oldest to newest. I’m trying to figure out a way to either do newest to oldest, or alphabetize based on animal names. The data is loaded via the following code: And the code that creates the list

PHP Iterate Multiple Children from XML

I’m trying to read an XML file in PHP which has multiple same-named nodes inside a parent. So far, I can read the first iteration of the XML node but then PHP moves to the next parent even though …

Proper way to send (POST) xml with guzzle 6

I want to perform a post with guzzle sending an xml file. I did not find an example. What I ‘ve done so far is : No matter what I try I get back error -1 which means that xml is not valid. XML that I send passes online validation though and is valid %100 Please help. Answer After some

Advertisement