Wiki source code of XWikiSyntaxTables

Version 1.1 by superadmin on 2025/05/22 17:44

Show last authors
1 = Editing =
2
3 == Tables ==
4
5 === 1.0 Tables ===
6
7 Allows to easily create content in table format.
8
9 |=Feature|=XWiki Syntax 1.0|=Result
10 |Standard table|((({{{
11 {table}
12 Title 1 | Title 2
13 Word 1 | Word 2
14 {table}
15 }}})))|(((
16 |=Title 1|=Title 2
17 |Word 1|Word 2
18 )))
19 |Parametrized table|(((
20 <table style="background-color:red;text-align:center">
21 <tbody>
22 <tr>
23 <td>Title 1</td>
24 <td style="background-color:yellow">Title 2</td>
25 </tr>
26 <tr>
27 <td>Word 1</td>
28 <td>Word 2</td>
29 </tr>
30 </tbody>
31 </table>
32 )))|(((
33 (% style="background-color:red;text-align:center" %)
34 |=Title 1|=(% style="background-color:yellow" %)Title 2
35 |Word 1|Word 2
36 )))
37 |Filterable Sortable table|((({{{
38 $xwiki.ssfx.use("js/xwiki/table/table.css")
39 $xwiki.jsfx.use("js/xwiki/table/tablefilterNsort.js", true)
40 <table id="table1id" class="grid sortable filterable doOddEven">
41 <tr class="sortHeader">
42 <th>Title 1</th>
43 <th>Title 2</th>
44 </tr>
45 <tr>
46 <td>Cell 11</td>
47 <td>Cell 12</td>
48 </tr>
49 <tr>
50 <td>Cell 21</td>
51 <td>Cell 22</td>
52 </tr>
53 </table>
54 }}}
55
56 {{info}}For improved features see the [[Livetable Macro>>https://extensions.xwiki.org/xwiki/bin/view/Extension/Livetable+Macro]].{{/info}}
57 )))|(((
58 {{velocity}}
59 $xwiki.ssfx.use("js/xwiki/table/table.css")
60 $xwiki.jsfx.use("js/xwiki/table/tablefilterNsort.js", true)
61 {{/velocity}}
62
63 (% class="grid sortable filterable doOddEven" id="table1id" %)
64 (% class="sortHeader" %)|=Title 1|=Title 2
65 |Cell 11|Cell 12
66 |Cell 21|Cell 22
67 )))
68
69 === 2.0 Tables ===
70
71 Allows to easily create content in table format. Parameters for table, row or cell are also supported in XWiki Syntax {{velocity}}$crtSyntaxVer{{/velocity}}.
72
73 |=Feature|=XWiki Syntax {{velocity}}$crtSyntaxVer{{/velocity}}|=Result
74 |Standard table|((({{{
75 |=Title 1|=Title 2
76 |Word 1|Word 2
77 }}}))) or ((({{{
78 !=Title 1!=Title 2
79 !!Word 1!!Word 2
80 }}})))|(((
81 |=Title 1|=Title 2
82 |Word 1|Word 2
83 )))
84 |Parametrized table|((({{{
85 (% style="background-color:red;text-align:center" %)
86 |=Title 1|=(% style="background-color:yellow" %)Title 2
87 |Word 1|Word 2
88 }}})))|(((
89 (% style="background-color:red;text-align:center" %)
90 |=Title 1|=(% style="background-color:yellow" %)Title 2
91 |Word 1|Word 2
92 )))
93 |Filterable Sortable table|((({{{
94 {{velocity}}
95 $xwiki.ssfx.use("js/xwiki/table/table.css")
96 $xwiki.jsfx.use("js/xwiki/table/tablefilterNsort.js", true)
97 {{/velocity}}
98
99 (% class="grid sortable filterable doOddEven" id="tableid" %)
100 (% class="sortHeader" %)|=Title 1|=Title 2
101 |Cell 11|Cell 12
102 |Cell 21|Cell 22
103 }}}
104
105 {{info}}For improved features see the [[Livetable Macro>>https://extensions.xwiki.org/xwiki/bin/view/Extension/Livetable+Macro]].{{/info}}
106 )))|(((
107 {{velocity}}
108 $xwiki.ssfx.use("js/xwiki/table/table.css")
109 $xwiki.jsfx.use("js/xwiki/table/tablefilterNsort.js", true)
110 {{/velocity}}
111
112 (% class="grid sortable filterable doOddEven" id="tableid" %)
113 (% class="sortHeader" %)|=Title 1|=Title 2
114 |Cell 11|Cell 12
115 |Cell 21|Cell 22
116 )))