chuckey
chuckey

Reputation: 1

Reverse the entries in an HTML table

I have a webpage on our intranet with a table,

I have approx 10k records on it , is there a quick easy way to turn the whole table upside down (e.g. at the moment it goes 1 , 2 , 3 ) how can I change it to go 10000, 9999, 9998 ?

Upvotes: 0

Views: 673

Answers (1)

jrd1
jrd1

Reputation: 10716

Depending on what is available to you, you can do it one of two ways: server-side or client-side.

Server-side of course depends on what technologies are available to you (e.g. PHP), and a solution of that sort will be simply reversing the beginning the ending indexes of whatever function / loop that generates the table.

Alternatively, you can use Javascript / jQuery in a client-side solution. In your case, a plugin much like this one may be your best bet:

http://tablesorter.com/docs/

Good luck!

Upvotes: 1

Related Questions