Difference: TablePlugin (22 vs. 23)

Revision 232005-03-27 - TWikiContributor

Line: 1 to 1
Added:
>
>
 

Table Plugin

Gives extra control of table display:

Line: 11 to 13
 
    • A TABLEATTRIBUTES preferences setting on site-level (TWikiPreferences) or web-level (any WebPreferences), e.g.
      • Set TABLEATTRIBUTES = tableborder="0" cellpadding="1" ...
    • Before a table using %TABLE{...}%
Added:
>
>
  • Row spans
 

Sorting

Line: 23 to 26
 
  • number is digits, with optional decimal point
  • otherwise treated as text
Added:
>
>

Row spans

Table cells with a single caret indicate follow-up rows of multi-row spans. For example,

| One One | One Two | One Three |
| ^ | Two Two | Two Three |
| Three One | ^ | Three Three |
One One One Two One Three
Two Two Two Three
Three One Three Three
 

TablePlugin Global Settings

Plugin settings are stored as preferences variables. To reference

Line: 34 to 52
 
  • Set DEBUG to 1 to get debug messages in data/debug.txt. Default: 0
    • Set DEBUG = 0
Changed:
<
<
  • Make sortable:
    • #Set SORT = attachments
    • Set SORT = all
>
>
  • Make all tables in a topic sortable. If this is set to all, all tables that have a header row (including those that do not have %TABLE before them) will be made sortable. If set to none, only tables with %TABLE will be sortable. Topic rendering is faster if this is set to none.
 
    • #Set SORT = none
Added:
>
>
    • Set SORT = all
 
  • Default table attributes:
Changed:
<
<
    • Set TABLEATTRIBUTES = tableborder="1" cellpadding="0" cellspacing="1" headerbg="#99CCCC" databg="#FFFFCC, #FFFFFF"
>
>
    • Set TABLEATTRIBUTES = tableborder="0" cellpadding="1" cellspacing="1" headerbg="#dadada" headercolor="#000000" databg="#eaeaea, #ffffff"
    • Classic skin table attributes:
      • #Set TABLEATTRIBUTES = tableborder="1" cellpadding="0" cellspacing="1" headerbg="#99CCCC" databg="#FFFFCC, #FFFFFF"
 

Table Attributes

Line: 63 to 81
 
valign Vertical alignment of cells, set to "top", "middle", "bottom" or "baseline" valign="top"
headeralign Header cell alignment, one value for all columns, or a comma separated list for different alignment of individual columns. Set to "left", "center", "right" or "justify". Overrides individual cell settings headeralign="left, right"
dataalign Data cell alignment, one value for all columns, or a comma separated list for different alignment of individual columns. Set to "left", "center", "right" or "justify". Overrides individual cell settings dataalign="center"
Changed:
<
<
tablewidth Table width: Percentage of window width, or absolute pixel value. Default is unspecified tablewidth="100%"
columnwidths Column widths: Comma delimited list of column widths, percentage or absolute pixel value. Default is unspecified columnwidths="80%, 20%"
>
>
tablewidth Table width: Percentage of window width, or absolute pixel value. Default is unspecified. tablewidth="100%"
columnwidths Column widths: Comma delimited list of column widths, percentage or absolute pixel value. Default is unspecified. columnwidths="80%, 20%"
 
headerrows Number of header rows to exclude from sort; default "1" headerrows="1"
footerrows Number of footer rows to exclude from sort; default "0" footerrows="1"
Added:
>
>
id Table identifier string. Default is unspecified. id="userTable"
summary Table summary used by screenreaders: A summary of what the table presents. It should provide an orientation for someone who listens to the table. Default is unspecified. summary="List of subscribed users"
caption Table caption: A title that will be displayed just above the table. Default is unspecified. caption="Users"
  The %TABLE{...}% settings override TABLEATTRIBUTES preferences settings, which override the TABLEATTRIBUTES Plugin settings.
Line: 74 to 95
 

Use of %TABLE{...}%

Changed:
<
<
Line before table: %TABLE{ sort="on" tableborder="0" cellpadding="1" cellspacing="3" headerbg="#000099" headercolor="#FFFFCC" databg="#C8CB8F, #DBDDB5" headerrows="2" footerrows="1" }%
>
>
Line before table: %TABLE{ sort="on" tableborder="0" cellpadding="1" cellspacing="3" headerbg="#D5CCB1" headercolor="#666666" databg="#FAF0D4, #F3DFA8" headerrows="2" footerrows="1" }%
 
Changed:
<
<
>
>
 
Table with two Header Rows and Footer Row
Num Status Action Who When Progress
1 C Chose new colours John 1-Dec-02  
Line: 94 to 115
 
2-Jan-2005

Plugin Installation Instructions

Changed:
<
<
Note: You do not need to install anything on the browser to use this plugin. Below installation instructions are for the administrator who needs to install this plugin on the TWiki server.
>
>
This plugin is pre-installed with your TWiki release. You should not have to install it other than to do an upgrade.
 
  • Download the ZIP file from the Plugin web (see below)
  • Unzip TablePlugin.zip in your twiki installation directory. Content:
Line: 106 to 126
 
pub/TWiki/TablePlugin/diamond.gif Diamond symbol
pub/TWiki/TablePlugin/down.gif Down arrow
pub/TWiki/TablePlugin/up.gif Up arrow
Added:
>
>
  • (Dakar) Visit configure in your TWiki installation, and enable the plugin in the {Plugins} section.
 
  • Test if the plugin is correctly installed:
    • Check above example if the table renders as expected
    • Try click on heading to sort. Other tables should also be sortable
Line: 113 to 134
 

Plugin Info

Plugin Author: TWiki:Main/JohnTalintyre, TWiki:Main/PeterThoeny
Changed:
<
<
Plugin Version: 01 Aug 2004
>
>
Plugin Version: 1.014
 
Change History:
<-- specify latest version first -->
 
Added:
>
>
13 Dec 2005 AC: Added support for id, summary and caption
5 Mar 2005 1.014: Crawford Currie eliminated deprecated handlers for Dakar
 
01 Aug 2004: AC: Added CSS support for first column and ascending/descending table headers
21 Mar 2004: PTh: Internal change: Fixed reference to unofficial variable
01 Jan 2004: PTh: Alternating data row colors restart again after each header row
Line: 139 to 162
  Related Topics: TWikiPreferences, TWikiPlugins, StandardColors
Deleted:
<
<
-- TWiki:Main/JohnTalintyre - 07 Oct 2001
-- TWiki:Main/PeterThoeny - 01 Aug 2004
 
Changed:
<
<
META FILEATTACHMENT attr="" comment="Up arrow" date="1070351625" name="up.gif" path="C:\Data\MyTWiki\Plugins\TablePlugin\pub\TWiki\TablePlugin\up.gif" size="867" user="PeterThoeny" version="1.1"
META FILEATTACHMENT attr="" comment="Down arrow" date="1070351653" name="down.gif" path="C:\Data\MyTWiki\Plugins\TablePlugin\pub\TWiki\TablePlugin\down.gif" size="867" user="PeterThoeny" version="1.1"
META FILEATTACHMENT attr="" comment="Diamond symbol" date="1070351672" name="diamond.gif" path="C:\Data\MyTWiki\Plugins\TablePlugin\pub\TWiki\TablePlugin\diamond.gif" size="881" user="PeterThoeny" version="1.1"
>
>

META FILEATTACHMENT attr="" comment="Up arrow" date="1070351625" name="up.gif" path="C:\Data\MyTWiki\Plugins\TablePlugin\pub\TWiki\TablePlugin\up.gif" size="867" user="TWikiContributor" version="1.1"
META FILEATTACHMENT attr="" comment="Down arrow" date="1070351653" name="down.gif" path="C:\Data\MyTWiki\Plugins\TablePlugin\pub\TWiki\TablePlugin\down.gif" size="867" user="TWikiContributor" version="1.1"
META FILEATTACHMENT attr="" comment="Diamond symbol" date="1070351672" name="diamond.gif" path="C:\Data\MyTWiki\Plugins\TablePlugin\pub\TWiki\TablePlugin\diamond.gif" size="881" user="TWikiContributor" version="1.1"
 
This site is powered by the TWiki collaboration platform Powered by PerlCopyright © 1999-2019 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback
Note: Please contribute updates to this topic on TWiki.org at TWiki:TWiki.TablePlugin.