create new tag
, view all tags

Enhanced TablePlugin Sorting Features

I have added a few enhancements to the sorting capabilities on the TablePlugin code.

I have included an initial sort and an initial sort direction. This is very helpful in setting up the page such that it appears as you want it when a user first looks at it. You will need to read the specifics to get an idea of the full functionality, but here are the enhancements.

To specify the column you wish to sort by you need to us the keyword initsort . initsort is set to the column you wish to sort by starting with 1. Example:

%TABLE{initsort="1" initdirection="up"}%

To specify the direction you want the sort to go you use the keyword initdirection . The acceptable arguments to this parameter are up or down.

I have also added some code that will place small gif images to indicate the sorting directions. These need to be placed in the following directory http://twiki.org/p/pub/icn/ in order for the code to see the images.

The code is attached as well as the small gifs.

-- ShawnBradford - 09 Nov 2001

I have fixed a bug in my current release so that multiple tables are rendered correctly on one page.

-- ShawnBradford - 12 Nov 2001

Added the above capability with the new TWiki20011201 release of the TablePlugin module. Only a couple modifications. It is attached below.

-- ShawnBradford - 22 Feb 2002

This is now in the latest TablePlugin release, so this patch is now obsolete. (I did fix a problem where initsort did not switch off for subsequent tables)

-- PeterThoeny - 12 Mar 2002

Topic attachments
I Attachment History Action Size Date Who Comment
Perl source code filepm TablePlugin.pm r3 r2 r1 manage 13.9 K 2002-02-22 - 21:11 ShawnBradford TWiki20011201 TablePlugin Update
GIFgif down.gif r1 manage 0.1 K 2001-11-10 - 03:26 ShawnBradford down gif
GIFgif up.gif r1 manage 0.1 K 2001-11-10 - 03:27 ShawnBradford up gif
Edit | Attach | Watch | Print version | History: r5 < r4 < r3 < r2 < r1 | Backlinks | Raw View | Raw edit | More topic actions
Topic revision: r5 - 2002-03-13 - PeterThoeny
  • Learn about TWiki  
  • Download TWiki
This site is powered by the TWiki collaboration platform Powered by Perl Hosted by OICcam.com Ideas, requests, problems regarding TWiki? Send feedback. Ask community in the support forum.
Copyright © 1999-2018 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.