• Advertisement


This topic is now archived and is closed to further replies.

Javascript and HTML; making table, that can be sorted

This topic is 5215 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I need to make a table using html, and with the headings , if i click on them the data in that column will be sorted alphabetically using javascript. Ive made a html table, but i don't see how to make it rearange values for the sort.

<TR> <TD ALIGN = "center"> Product ID</TD>
<TD ALIGN = "center"> Product Name </TD>
<TD ALIGN = "center"> Product Description </TD>
<TD ALIGN = "center"> Quantity </TD>

<TD ALIGN = "center"> 41256 </TD>
<TD ALIGN = "center"> Compaq Presario </TD>
<TD ALIGN = "center"> Pentium 4, 2.4 GHz, 512 MB Ram </TD>
<TD ALIGN = "center"> 5 </TD>

<TD ALIGN = "center"> 61728 </TD>
<TD ALIGN = "center"> Diamond Monitor </TD>
<TD ALIGN = "center"> 17' LCD </TD>
<TD ALIGN = "center"> 12 </TD>
<TD ALIGN = "center"> 18692 </TD>
<TD ALIGN = "center"> Imation Super Disk</TD>
<TD ALIGN = "center"> 120 Mb floppy external drive </TD>
<TD ALIGN = "center"> 7 </TD>
<TD ALIGN = "center"> 51961 </TD>
<TD ALIGN = "center"> IBM Laptop </TD>
<TD ALIGN = "center"> Pentium 4, 2.0 Ghz, 256 MB Ram, active screen </TD>
<TD ALIGN = "center"> 4 </TD>
[edited by - johnnyBravo on November 17, 2003 8:38:33 AM]

Share this post

Link to post
Share on other sites

  • Advertisement