SMW queries
-
- Last edited 3 years ago by MLR
-
-
- No status information
Revision as of 14:00, 30 June 2021 by Mlink-rodrigue (talk | contribs)
Here you can see some examples for simple queries using the metadata of a wiki page. You can add these queries to any wiki page.
Contents
Creating page lists
{{#ask:
[[:+]]
[[Modification date::+]]<!-- necessary to filter deleted pages -->
|format=ul
|limit=4
}}
Notes:
[[:+]]
show Pages in the Main namespace. [[Myspace:+]]
shows pages in the namespace Myspace.
[[:+||Help:+]]
shows pages in the Main namespace and in the namespace Help.
Output in category style
{{#ask:
[[:+]][[Modification date::+]]
|format=category
|limit=12
}}
A
B
Show pages from a category
{{#ask:
[[Category:Administration]]
| limit=4
| searchlabel=
| format=ol
}}
Seiten mit gleichem Namensanfang
{{#ask:
[[~Visu*]][[:+||Manual:+]]
[[Modification date::+]]<!-- necessary to filter deleted pages -->
| limit=5
| searchlabel=
| format=ol
}}
List of pages in the Main namespace and in the namespace Manual that begin with "Visu".
- Visual version comparison (VisualDiff)
- VisualEditor
- VisualEditor/Tables/Examples
- VisualEditor/Version comparison
- VisualEditor: Insert Images
Results format: Table
Format "broadtable"
{{#ask:
[[~Visu*]][[:+||Manual:+]]
[[Modification date::+]]<!-- necessary to filter deleted pages -->
| limit=5
| searchlabel=
| format=broadtable
}}
Visual version comparison (VisualDiff) |
VisualEditor |
VisualEditor/Tables/Examples |
VisualEditor/Version comparison |
VisualEditor: Insert Images |
Format "datatable"
{{#ask:
[[~Visu*]][[:+||Handbuch:+]]
[[Modification date::+]]<!-- necessary to filter deleted pages -->
| limit=5
| searchlabel=
| format=table
| class=datatable
}}
Important!
The format declaration|format=datatablecurrently does not work with the BlueSpice skin. Instead, use the following syntax:
|format=table |class=datatable
Related info