Wrox Home  
Search P2P Archive for: Go

  Return to Index  

javascript_howto thread: Conditional Table Rows


Message #1 by "Chris Cote" <cotec@s...> on Thu, 21 Feb 2002 16:01:36
If you use a string array with 3 elements, and set each equal to the code for the last row:

lastrow[0]="<TR><TD>I am row option #1</TD></TR>";
lastrow[1]="<TR><TD>I am row option #2</TD></TR>";
lastrow[2]="<TR><TD>I am row option #3</TD></TR>";

... then you could use a document.write(lastrow[ choice ]), or a variant thereof, to display the proper last row. Where the
drop-down is in relation to the table will determine how you throw the parameter, but at least this should handle the row aspect.

Shawn

  Return to Index