Hjælp til XML attributes med PHP
Hej alle.Skal bruge en PHP løsning, som kan udskriver de ting som står i attributer inde i de forskellige childs.
Her er koden:
<livescore-feed-document timestamp_created="1271357806">
−
<matches-list total-count="50">
−
<match id="cb3dfd030f7a2673a817f47b88a392fa" timestamp-starts="1271268000" status="finished">
<contest value="spa_ll">Spain - Primera Division</contest>
−
<teams>
<hosts>Atletico</hosts>
<guests>Xerez</guests>
</teams>
<score>1 - 2</score>
</match>
−
<match id="461a71ee46c11b269e98a57577e2c327" timestamp-starts="1271268000" status="finished">
<contest value="spa_ll">Spain - Primera Division</contest>
−
<teams>
<hosts>Zaragoza</hosts>
<guests>Mallorca</guests>
</teams>
<score>1 - 1</score>
</match>
−
<match id="fe3a0319b391e453fe92cb28c0b522bf" timestamp-starts="1271275200" status="finished">
<contest value="spa_ll">Spain - Primera Division</contest>
−
<teams>
<hosts>Barcelona</hosts>
<guests>Deportivo</guests>
</teams>
<score>3 - 0</score>
</match>
-</matches-list>
</livescore-feed-document>
F.eks: Hvordan udskriver jeg <match id="">
Håber i kan hjælpe :)