Wiki Pages

XWiki Page Structure

The main XWiki entity is the wiki page or document. Up until version 7.2, we used the notion of wiki space which is a collection of wiki pages having 2 special documents:

  • WebHome - the landing page (or home page) of the space
  • WebPreferences - a document storing the space attributes like: skin, color theme, access rights, panels and so on

A space inherits the rights and administration settings from the wiki and a page inherits the rights and administration settings from the space it belongs to. 

A page can have one or more child pages and a parent. If a page doesn't have a parent, it is called orphan. Most importantly, it is not mandatory for the parent to be in the same space or even in the same wiki.  

Starting with XWiki Enterprise 7.2, we have introduced the possibility to create pages inside other pages - this new feature is called Nested Pages and comes with 3 new concepts:

  • Nested Page or Non-Terminal Page is a wiki page that can have child pages.
  • Non-Nested Page or Terminal Page is a wiki page that cannot have children and it is usually created by applications and scripts.
  • Nested Space is a space having another space as parent. Visually, users handle just Nested Pages which are emulated using Nested Spaces.
Simple users can create only nested pages, whereas Advanced users can create both nested and terminal pages.

The advantages or using nested pages include:

  • improved and simplified manner to organize your content hierarchically
  • ability to set permissions at each level
  • the page hierarchy is reflected in the URL
  • the entire hierarchy is updated whenever a page is renamed or deleted

You can still use the sub-wiki alternative in 2 main cases:

  • the need to provide custom applications and/or extensions to a group of wiki users but not to others
  • the need to implement a wiki farm where each sub-wiki has its own users and applications

Create a New Blank Page

To create a new wiki page, go to any document and click the "+" button.

CreatePageButton.png

If you are an advanced user, the page creation form has 4 elements, otherwise, you will see only the first 3 of them:

  • Title - the page title
  • Page Type - in case there are page templates available, you can choose either one of them or the "Blank Page" template, which is the default one. 
  • Location - the place in the page hierarchy where the new document will be created.
  • Terminal Page - this option is available only for advanced users and it allows to create a non-nested page i.e. a document that cannot have children.

PageCreationForm.png

More information about how to create and manage generic page templates is available in the "Template Providers" documentation listed under "Related Pages".

To set the page location, click the blue editing pen icon, which will load 2 more fields:

  • Parent - the parent of the new page; right after starting to type the name, the suggest feature will display the list of all the occurrences, so that you can select from them. To collapse the suggestion results, just click on "hide suggestions". As soon as you select a parent, the breadcrumb is updated in order to reflect the location of the page in the reference hierarchy.

By leaving this field empty, you will create a top-level page which is the equivalent of an old space home page. 

  • Name - the name of the page i.e. the string appearing in the URL.

PageLocationForm.png

Another way of selecting a location is to click on the blue hierarchy icon

PageLocationIcon.png

and select a space from the document tree or to search it using the integrated finder.

DocumentTree.png

Starting with version 7.4.1, the editing pen icon and the advanced edit fields like the wiki, parent and page name are hidden for simple users who will have to use the tree picker to select the target location.

CreatePageSimpleUsers.png

Once you are done filling the form, click on "Create". Your new document will open in edit mode, Wysiwyg or text, depending on what you have chosen in your user preferences page. In the editor window you may add content to the newly created page.

CreatePageWysiwyg.png

Once you are done adding content, save the page to finalize the process.

If you decide to create a terminal page, it is mandatory to set a parent for it.

CreateNewPage.png

When creating a new page, the system automatically creates a [PageName].WebHome, which creates a space, though this is hidden in the URL. For instance, the nested page "MarketingMeetingNotesNovember2015" has a corresponding "MarketingMeetingNotesNovember2015.WebHome".

Another way to create a new blank page is straight from the URL, by entering the new page name in the address bar of your browser. If the page doesn't exist, you will the message "The requested document could not be found". Also, there will be an "edit this page" link to create it.

CreateNewPageURL.png

Create a Dashboard

To create a dashboard, go to any page and click the "+" button, as explained in the previous section and:

  • fill in the title and name - in our case they are both set to "Applications"
  • leave the "Parent" field empty in order to create a top-level nested page
  • select the "Dashboard - Customisable gadgets" option under "Page Type" -> "Templates"

SpaceDashboardParameters.png

After clicking on "Create", the new page will open in "Inline" mode. The dashboard already has 2 columns and 3 default gadgets:

  • Page index using the Document Tree Macro
  • Tag Cloud
  • Activity Stream

but you can further customize it by adding gadgets and columns.

SpaceDashboardTemplate.png

Page Hierarchy

Due to the decision to start using Nested Pages, the old Parent-Child relationship was dropped. Thus, the functionality is turned off by default. A system administrator can enable it at any time by setting the core.hierarchyMode property to parentchild in the /WEB-INF/xwiki.properties configuration file, followed by a server restart. 

The new breadcrumb has been reworked to reflect the location of a page in the reference hierarchy. Each breadcrumb element has a drop-down tree that shows the siblings and the children, helping you navigate easily around the wiki. In the table below you can see the breadcrumb for terminal and non-terminal pages and also what appears in the "Spaces" widget after creating a nested page (top-level or not).

Non-Terminal Page

Breadcrumb
NonTerminalPageBreadcrumb.png
"Spaces" Widget
NonTerminalPageSpaces.png

Terminal Page

Breadcrumb
TerminalPageBreadcrumb.png

Non-Terminal Top-Level Page

Breadcrumb
NonTerminalTopLevelPageBreadcrumb1.png   NonTerminalTopLevelPageBreadcrumb2.png
"Spaces" Widget
NonTerminalTopLevelPageSpaces.png

Since adopting the nested pages feature, the ability to modify the page parent has been removed in edit mode. 

PageParentEditMode.png

This is why, to change the parent of a page, you will have to rename it, as indicated in the 'Nested Page Actions' documentation.

New Default Templates

Starting with version 8.2 XWiki provides 4 new default templates containing pre-created page structures that can be used immediately.

The "Simple Page" template is basically the "Blank Page" template with 2 extra macros: "Box" and "Table of Contents". 

The "Article Page" template allows to create a news article-like page with:

  • a summary wrapped in a Jumbotron component
  • the content of the article displayed in the column on the left
  • a table of contents (generated using the "Box" and "Table of Contents" macros) and associated images displayed in the column on the right
Simple Page TemplateArticle Page Template
SimplePageTemplate.png
ArticlePageTemplate.png

The "Encyclopedia Page" template is similar to "Article Page" with one difference: the images from the column on the right are replaced with a single image and a table wrapped in a box container.

The "Meeting Report" template allows to easily store meeting notes and agenda.

Encyclopedia Page TemplateMeeting Report Template
EncyclopediaPageTemplate.png
MeetingReportTemplate.png

                  

Search this space