SimpleXML question

suklee

Diamond Member
Oct 9, 1999
4,575
10
81
Hi,

This is the link to the XML I am working with: link. The requirements state that I only need to output 5 tags for each "event":

  1. title
  2. city
  3. state
  4. start_date (without time)
  5. link - which is an http URL

Will I run into any issues using SimpleXML to read this XML file and output it as HTML?

How would I 'skip over' the elements I don't want and just output the 5 specific targets that I am after?

Any other gotchas I might need to watch out for? I'm fairly new to the world of XML.

Thanks!

PS. I will be using PHP 5.2.8
 

imported_Dhaval00

Senior member
Jul 23, 2004
573
0
0
I guess none of the PHP gurus here saw this. From the looks of it, I am sure you can simply use the SimpleXMLElement::xath function to get all those node (http://us.php.net/manual/en/fu...xml-element-xpath.php). It seems there is very good community feedback at the bottom of that function.

I am not a PHP-pro. So if I am wrong, I am assuming one of the PHP-pros here will point you to alternate solution(s).