Guide de syntaxe XWiki

Modifié par superadmin le 2022/06/05 23:31

Syntaxe XWiki 2.1: Tableaux

2.0 Tables

En syntaxe XWiki 2.0, il est également possible d'avoir des paramètres pour le tableau, la ligne ou la cellule.

FonctionnalitéSyntaxe XWiki 2.1Résultat
Tableau standard
|=Titre 1|=Titre 2
|Mot 1|Mot 2
ou
!=Titre 1!=Titre 2
!!Mot 1!!Mot 2
Titre 1Titre 2
Mot 1Mot 2
Tableau paramétré

|=Titre 1|=(% style="background-color: yellow" %)Titre 2
|Mot 1|Mot 2

Titre 1Titre 2
Mot 1Mot 2
Tableau filtrable et pouvant
être trié
{{velocity}}
$xwiki.ssfx.use
("js/xwiki/table/table.css")
$xwiki.jsfx.use
("js/xwiki/table/tablefilterNsort.js", true)
{{/velocity}}

{{html}}
<table id="tableid" 

class="grid sortable filterable doOddEven"> <tr class="sortHeader"> <th>Titre1</th> <th>Titre2</th> </tr> <tr> <td>Cellule11</td> <td>Cellule12</td> </tr> <tr> <td>Cellule21</td> <td>Cellule22</td> </tr> </table> {{/html}}

Titre1 Titre2
Cellule11 Cellule12
Cellule21 Cellule22