Fullscreen
[Show/Hide Left Column]
[Show/Hide Right Column]

Displays a table using TikiWiki odd/even style
3d browser Print

Plugin FancyTable

This plugin displays the data using the Tiki odd/even table style.

Usage

The data (and the head parameter) is given one row per line, with columns separated by ~|~ (or separated by | starting with 4.0).

To display a fancy table in a wiki page, use the syntax:
{FANCYTABLE(head=> ,headclass=> )}cells{FANCYTABLE}


Future versions (with 4.0 and after):
{FANCYTABLE(head=h1c1|h1c2|h1c3>>h2c1|h2c2|h2c3 , headclass= , headaligns=left|right|center|justify , headvaligns=top|middle|bottom|baseline , colwidths= , colaligns=left|right|center|justify , colvaligns=top|middle|bottom|baseline , sortable= , sortlist= )}cells{FANCYTABLE}



Parameter Accepted values Effect Optional Since
head text separated by | (starting with 4.0) or ~|~ (all versions) for each cell
separate by >> for each header row (with 4.2)
Creates specially formatted header cells and rows optional
(body - between FANCYTABLE tags) text separated by | (starting with 4.0) or ~|~ (all versions) for each cell Creates cells in the body of the table. Start a new line to start a new row. required
headclass Any valid CSS class Applies class styling to the header rows optional 2.0
sortable y or n allows to be able to sort the columns with javascript optional 4.0
sortlist [0,1],[1,0]...
Pairs of numbers for: [columnIndex, sortDirection],... where columnIndex is a zero-based index for the columns left-to-right, and sortDirection is 0 for ascending and 1 for descending. Example that sorts ascending first by column 1 and then column 2: [0,0],[1,0]
Table is initially pre-sorted according to this setting. optional 4.0
(in any cell) one or more forward slashes (/) or backslashes (\) at the beginning of the cell Cell will span the number of columns indicated by the number of forward slashes, and will span the number of rows indicated by the number of backslashes. optional 4.0
headaligns
colaligns
left
right
center
justify
Aligns text horizontally in header columns (headaligns) or table body columns (colaligns). Separate setting for each column by a | optional 4.1
headvaligns
colvaligns
top
middle
bottom
baseline
Aligns text vertically in header columns (headvaligns) or table body columns (colvaligns). Separate setting for each column by a | optional 4.1
colwidths number of pixels followed by 'px', or percent followed by '%', for each column separated by a | Sets the width of the columns optional 4.1


Close
note Note
Sorting a table with cells that span multiple columns or rows can give unexpected results.


Example

Example:
This code:

{FANCYTABLE( head=" Quantity | Vegetables | Fruits", sortable="y",sortList="[0,0],[1,0]")}
10 | onions | apples
10 | cucumbers | lemons
100 | carrots | oranges
10 | tomatoes | water melons
50 | peas | strawberries
{FANCYTABLE}

.
Would produce:

Quantity Vegetables Fruits
10 onions apples
10 cucumbers lemons
100 carrots oranges
10 tomatoes water melons
50 peas strawberries



Sort

Available starting with TikiWiki version 4.0

The sortable parameter uses jquery, so the following must be enabled for it to work:
  • Go to Admin home > Editing and Plugins > Plugins (tab) and click on jq to enable the wikiplugin jq.
  • Go to Admin Home > Look and Feel > UI Effects and click on "JQuery Sortable Tables".

See a live example in the table above showing the fancytable parameters. See http://tablesorter.com (external link) for more information on the base jq plugin being used.


Contributors to this page: lindon1688 points  , xavidp820 points  , marclaporte4506 points  , sylvie3000 points  , btiffin5 points  , Xavi26092 points  and system .
Page last modified on Monday 14 December, 2009 05:12:49 UTC by lindon1688 points .

To register

To have an account at this site, please register at Tikiwiki.org (external link), and then use that user name and password to log in here.

Find by Page Name

Exact match

Keywords

The following is a list of keywords that should serve as hubs for navigation within the Tiki documentation and should correspond to development keywords (bug reports and feature requests):

Accessibility (WAI – 508)
Action log 2.x
Alert 3.x
Articles & Submissions
Backlinks
Banners
Blog
Bookmark
Browser Compatibility
Cache
Calendar
Category
Chat
Clean URLs
Comments
Communication Center
Compression (gzip)
Contacts Address book
Contact us
Content template
Contribution 2.x
Cookie
Copyright
Custom Home (and Groups Home Page)
Date and Time
Debugger Console
Directory (of hyperlinks)
Documentation link from Tiki to doc.tikiwiki.org (Help System)
DogFood
Dynamic Content
Dynamic Variable
External Authentication
FAQ
Featured links
File Gallery
Forum
Friendship Network (Community)
Gmap Google maps
Groups
Hotword
HTML Page
i18n (Multilingual, l10n, Babelfish)
Image Gallery
Import-Export
Install
Integrator
Interaction
Inter-User Messages
InterTiki
Karma
Live Support
Login
Look and Feel
Lost edit protection
Mail-in
Map with Mapserver
Menu
Meta Tags
Mobile Tiki and Voice Tiki
Mods
Module
MultiTiki
MyTiki
Newsletter
Notepad
Payment
Performance Speed / Load
Permissions
Platform independence (Linux-Apache, Windows/IIS, Mac, BSD)
Polls
Profile Manager
Quicktags
Quiz
Rating
Feeds
Score
Search engine optimization
Search
Security
Semantic links 3.x
Shadowbox
Shoutbox
Slideshow
Smarty Template
Smiley
Spam protection (Anti-bot CATPCHA)
Spellcheck
Spreadsheet
Stats
Surveys
System log
Tags 2.x
Task
Tell a Friend + Social Bookmarking 2.x
TikiTests 2.x
Theme
Trackers
TRIM
User Administration including registration and banning
User Files
User Menu
Watch
WebHelp
Webmail
Webservices
Wiki 3D
Wiki History, page rename, etc
Wiki Page Staging and Approval 2.x
Wiki Plugins extends basic syntax
Wiki Syntax
Wiki structure (book and table of content)
WYSIWYCA
WYSIWYG 2.x
XMLRPC