Sometimes it is handy to reuse the design of a page or content item in another place, for example on an educational website where the same page is used as an introduction for each course that is offered. It would be a waste of time to have to design the introduction page again and again each time a new course is added. Why should you have to reinvent the wheel when the design has already been imagined and created?
For situations like this, the Template-widget is the solution because it offers the possibility to copy the design of a page or content item and then you can get straight to work with the new version.
Step 1: install the widget
The Template-widget is not present by default in an XperienCentral installation. You can get it free by submitting a request to our Customer Service department. As soon as the widget has been installed, you can add it to one of the Sidebars in the Workspace using the plus (+) icon. The Template-widget appears as follows:
Step 2: add templates
When you open the Template-widget, you will see all the available templates. The chance is high that the first time you open the widget you won’t see any templates because none have been added yet. The way you create a template out of a page is different to the way you do so from a content item — both methods are described below.
Create a template from a page
- Navigate to the page for which you want to create a template.
- Click [Edit] in the Properties-widget.
- On the Basic tab, click [Adjust] next to Labels.
- Select the Assigned tab and then select the label ‘template’ in the Available labels*
- Click [Add label>].
- Click [Apply].
- After refreshing the page by clicking [F5], the page is added to the Templates-widget.
* If you don’t see the ‘template’ label, then you can create it as follows: click the Maintain tab, enter ‘template’ in the New Label field, click [Create] and then click [Apply]. Click the Assign tab and it will now be in the list of available labels. Repeat the steps given above.
Create a template from a content item
- Navigate to the content item for which you want to create a template.
- Click [Edit] in the Properties-widget.
- On the Basic tab, click [Select Tags] next to
- In the Available tags column, select ‘template’.
- Click [Add] and then [Apply] and then [Close].
- Click [Save] in the Properties dialog and then [Close].
- After refreshing the page by clicking [F5], the content item is added to the Templates-widget.
* If you don’t see the ‘template’ tag, then you can create it as follows: Open the Content Repository (Configuration > Content Repository). On the Tags tab, click [Add Tag]. Enter ‘template’ in the Add Tag field and then click [Add] and then [Apply]. Close the Content Repository by clicking [Apply] and then [Close]. Repeat the steps given above.
Step 3: make use of a template
As soon as a template is added to the Template-widget, you can use it to create a new page or content item. Follow these steps:
- Open the Template-widget.
- Click on the Copy icon to the right of the template name.
- A copy of the page/content item is created. The copy that is created is exactly the same as the template except for labels (for pages) and tags (for content items). In the case of a new page, it will be created as a child page of the currently selected page in the Site Structure widget and be in the ‘planned’ state.
Remarks
The Template-widget works with XperienCentral versions 10.4.0 and higher (Maven 2 and 3). The Dojo Servlets-widget is also required which GX Software will also deliver with the implementation of the Templates-widget.
In principle, the Template-widget works fine with all standard pages and content items in XperienCentral. For custom content items, it is a question of testing. If it turns out not to work with your custom content items, please contact our Customer Services department.
Comments
0 comments
Please sign in to leave a comment.