Question about a kirupa tutorial

Hello,

I just went through this tutorial and I have what I am hoping is a simple question/request.

The XML document that I’ve being given to work with contains a huge amount of data. It’s weather for a number of geographically located stations. The thing is that I only need to worry about one or two of those stations. Each station looks to be unique thanks to an attribute…


<reporting-station code="LFPB">
    <city>Paris</city>
    <state>France</state>
    <forecast-day>
        <day>Thursday</day>
        <high>67</high>
        <low>46</low>
        <sky-conditions>Rain</sky-conditions>
    </forecast-day>
</reporting station>

<reporting-station code="KNOU">
    <city>Budapest</city>
    <state>Hungary</state>
    <forecast-day>
        <day>Thursday</day>
        <high>71</high>
        <low>53</low>
        <sky-conditions>Partly Cloudy</sky-conditions>
    </forecast-day>
</reporting station>

Using the above linked tutorial I’ve been able to get it to display all stations but I need to tell it to only display particular stations. I’m sure there’s an IF statement in my future but I’m both an XML and PHP novice, so I’m hoping someone can help me out.