Hi,
I ahve got an xml document that is returned from a webservice call that i need to output to the browser. the xml document details which seats are available within a theatre, and will only return the seats that are available.
I need to be able to loop over this xml document and output row by row the seats that are available.
the xml doc is like this:
<availableSeats>
<Table>
<xpos>7</xpos>
<ypos>1</ypos>
<seat_Status>4</seat_Status>
</Table>
<Table>
<xpos>7</xpos>
<ypos>2</ypos>
<seat_Status>4</seat_Status>
</Table>
<Table>
<xpos>8</xpos>
<ypos>2</ypos>
<seat_Status>4</seat_Status>
</Table>
<Table>
<xpos>9</xpos>
<ypos>3</ypos>
<seat_Status>4</seat_Status>
</Table>
</availableSeats>
what i need to be able to do is to keep an eye on the xpos element and if it changes to a different value, to start another row in my html table. Now i've experimented using variables and have found that they don't seem to allow the value to be changed once they have been set (very useful!). Can anyone point me in the direction of something that could help me with this? Without being able to make a new row dynamically I can't think how to do this.
TIA
Tony
I ahve got an xml document that is returned from a webservice call that i need to output to the browser. the xml document details which seats are available within a theatre, and will only return the seats that are available.
I need to be able to loop over this xml document and output row by row the seats that are available.
the xml doc is like this:
<availableSeats>
<Table>
<xpos>7</xpos>
<ypos>1</ypos>
<seat_Status>4</seat_Status>
</Table>
<Table>
<xpos>7</xpos>
<ypos>2</ypos>
<seat_Status>4</seat_Status>
</Table>
<Table>
<xpos>8</xpos>
<ypos>2</ypos>
<seat_Status>4</seat_Status>
</Table>
<Table>
<xpos>9</xpos>
<ypos>3</ypos>
<seat_Status>4</seat_Status>
</Table>
</availableSeats>
what i need to be able to do is to keep an eye on the xpos element and if it changes to a different value, to start another row in my html table. Now i've experimented using variables and have found that they don't seem to allow the value to be changed once they have been set (very useful!). Can anyone point me in the direction of something that could help me with this? Without being able to make a new row dynamically I can't think how to do this.
TIA
Tony