Wiki Page Handler
Profile installer in Tikiwiki would not be very useful without wiki pages, thus, a
handler was created. To create a wiki page, the page content must exist in the profile repository. The page name is provided in the profile to reference to it.
The wiki handler cannot overwrite existing pages in a wiki. This will cause a handler error.
YAML
preferences:
enable: [ feature_wiki ]
objects:
-
type: wiki_page
ref: wiki_sample_page
data:
name: SamplePage
description: A sample page
lang: en
content: wikicontent:WikiHandlerSamplePage
Wiki Object Parameters
Field name | Mandatory | Value
|
type | yes | must be "wiki_page"
|
ref | | can link to a category or structure. see Object References.
|
name | yes | The name of the page to be created. Can be different from local pagename.
|
description | | The page description.
|
lang | | Page language as the two letter code (ex: fr, en, es)
|
content | yes | Initial page content. To simplify the profile, large pages can be included from a remote location in the same profile repository. This is done by using the wikicontent: prefix, as seen in the example. |
Details
minimally, to import a wiki page the following YAML syntax will suffice.
objects:
-
type: wiki_page
data:
name: todo
content: wikicontent:todo
- mind your spaces here each level of indentation is two spaces. (recommended). type and data are at the third level, name and content in the fourth.
- Re-import is ok you can load a profile multiple times in the same wiki. It will ask if you want to Forget the install - this will not remove data imported. When you re-install a profile anything new will be added, however . . .
- Profile Can't Overwrite Page Content - currently if you try to install a profile which modifies content on a wiki page that already exists, it will produce a handler error.
List of Profiles with Wiki Handler
Help_Pages
Contact_Form
Profile_Repository_Profile
Example_Wiki_Profile