]> CyberLeo.Net >> Repos - SourceForge/phpwiki.git/blob - pgsrc/Help%2FRichTablePlugin
function _PageList_Column* are not private
[SourceForge/phpwiki.git] / pgsrc / Help%2FRichTablePlugin
1 Date: Wed, 19 Dec 2012 13:19:04 +0000
2 Mime-Version: 1.0 (Produced by PhpWiki 1.4.0)
3 Content-Type: application/x-phpwiki;
4   pagename=Help%2FRichTablePlugin;
5   flags=PAGE_LOCKED%2CEXTERNAL_PAGE;
6   markup=2;
7   charset=UTF-8
8 Content-Transfer-Encoding: binary
9
10 The **~RichTable** [[Help:WikiPlugin|plugin]] is a plugin that takes off from the [[Help:OldStyleTablePlugin|OldStyleTable]] plugin. It allows a user to specify arbitrary properties of ##<table>##, ##<tr>## and ##<td>## with a very simple markup.
11
12 This plugin is included for legacy only. We recommand to
13 use [[Help:MediawikiTablePlugin|Mediawiki tables]] instead.
14
15 == Syntax ==
16
17 The contents of each cell are individually processed by the ~BlockParser. This means that you can do interesting things like put **invoke plugins**, use **enumerated lists** etc within each cell!
18
19 A ##"-"## (dash) at the start of a new line represents a new row in the table.
20
21 A ##"|"## (vertical bar or pipe) at the start of a new line represents a cell.
22
23 === Attributes for the tags ===
24
25 A line that starts with a ##"~*"## (star or asterisk) after a ##"|"## is parsed for attributes for the corresponding cell.
26
27 Attributes for the table are given on line that starts with a ##"~*"##, only if the line appears before any other line except whitespace.
28
29 A line that starts with a ##-## is always parsed for attributes since it can't have any content, unlike a cell.
30
31 === Cell contents ===
32
33 Cell contents are processed by the ~BlockParser.
34
35 Any line that starts with a ##"~*"## anywhere other than the table attribute line is treated as normal content.
36
37 Any line that starts with whitespace is also treated as content.
38
39 Any cell line that does not have a ##"~*"## after the ##"|"## is treated as normal content.
40
41 All content lines that follow a cell line are added to that cell. They can contain arbitrary text except the above cases.
42
43 If there is no cell in the current row, content lines are dropped silently.
44
45 === Special characters ===
46
47 The two special characters ##"~~"## and ##"?>"## should be escaped as ##"\~~"## and ##"?\>"##. I havn't discovered any other characters yet that might need to be escaped. This is required for the block parser to work.
48
49 === Attributes ===
50
51 We allow attributes with or without quotes ("):
52 {{{
53 border=1, cellpadding="5"
54 style="font-family: sans-serif; border-top:1px solid #dddddd;"
55 style="font-family: Verdana, Arial, Helvetica, sans-serif"
56 }}}
57
58 == Example ==
59
60 <<RichTable
61
62 *border=1, cellpadding=5, bgcolor=#f0f8f8, width=75%, align=center
63 -
64 |* colspan=3, align=center
65 HomePage
66 -
67 |* colspan=2
68 [http://phpwiki.svn.sourceforge.net/viewvc/phpwiki/trunk/themes/default/images/png.png]
69 |* rowspan=2
70 This cell actually has a plugin invocation inside it!
71 <?plugin
72 BackLinks
73 ?\>
74 - bgcolor=white
75 |
76 # One
77 # Two
78 |
79 * Foo
80 * Bar
81 - bgcolor=cyan
82 This line gets dropped ... no cell to contain it!
83 |* bgcolor=#f0f0ff, align=center
84 One paragraph
85
86 Another paragraph?
87 |* align=left
88 This cell uses the row color
89 | I wish this cell had a nested table inside it! :(
90 >>
91
92 The above table is rendered from:
93
94 {{{
95 <<RichTable
96
97 *border=1, cellpadding=5, bgcolor=#f0f8f8, width=75%, align=center
98 -
99 |* colspan=3, align=center
100 HomePage
101 -
102 |* colspan=2
103 [http://phpwiki.svn.sourceforge.net/viewvc/phpwiki/trunk/themes/default/images/png.png]
104 |* rowspan=2
105 This cell actually has a plugin invocation inside it!
106 <?plugin
107 BackLinks
108 ?\>
109 - bgcolor=white
110 |
111 # One
112 # Two
113 |
114 * Foo
115 * Bar
116 - bgcolor=cyan
117 This line gets dropped ... no cell to contain it!
118 |* bgcolor=#f0f0ff, align=center
119 One paragraph.
120
121 Another paragraph?
122 |* align=left
123 This cell uses the row color
124 | I wish this cell had a nested table inside it! :(
125 >>
126 }}}
127
128 == Known Bugs ==
129 * The plugin can't nest itself. Thus nested tables are currently not possible. See [[Help:MediawikiTablePlugin|Mediawiki tables]] to have nested tables.
130
131 == Author ==
132 * [[http://www.it.iitb.ac.in/~sameerds/phpwiki/index.php/RichTablePlugin|Sameer D. Sahasrabuddhe]]
133
134 <noinclude>
135 ----
136 [[PhpWikiDocumentation]] [[CategoryWikiPlugin]]
137 </noinclude>