Code: Select all
,Code: Select all
and [syntax="..."] tags where appropriate when posting code. Your post has been edited to reflect how we'd like it posted. Please read: [url=http://forums.devnetwork.net/viewtopic.php?t=21171]Posting Code in the Forums[/url] to learn how to do it too.[/color]
Hi,
I'm parsing some XML and then spitting it out on the screen. What I'd like to be able to do is reverse the array that SimpleXML creates but for the life of me, I can't do it. Here's some sample XML.
[syntax="xml"]<league>
<country>England</country>
<name>Premier League</name>
<all_matches>
<item>
<round>1</round>
<date>19 Aug 06</date>
<result>1 - 1</result>
<team1>Sheffield Utd.</team1>
<team2>Liverpool</team2>
</item>
<item>
<round>1</round>
<date>19 Aug 06</date>
<result>3 - 1</result>
<team1>West Ham United</team1>
<team2>Charlton</team2>
</item>
<item>
<round>1</round>
<date>19 Aug 06</date>
<result>1 - 1</result>
<team1>Arsenal</team1>
<team2>Aston Villa</team2>
</item>
</allmatches>
</league>
feyd | Please use[/syntax]
Code: Select all
,Code: Select all
and [syntax="..."] tags where appropriate when posting code. Your post has been edited to reflect how we'd like it posted. Please read: [url=http://forums.devnetwork.net/viewtopic.php?t=21171]Posting Code in the Forums[/url] to learn how to do it too.[/color]