project:_template

$v:%%revisions%% $t: %%fullname%% $a: %%updated_by%% $u: %%updated_at%% $

%%content{1}%%

%%content{2}%%

%%content{3}%%

%%content{4}%%

==========

content {1}

This is the default content {1 } for the template. When a new page in the category "project" is created,
it will automatically be filled with the following text.

This area can contain standard WikiDot syntax

To create a template for a category you create a page called "_template"
in that category. For the default category, the template page is called "_template".

For example

_template
category:_template
bugs:_template
proposals:_template

The purpose of a template is to define a layout of pages within a category.

Here is a simple template that forces the height of the content box.

Create a page called _template with this code, and then reload the start page of your site:

[[div style="min-height:600px"]]
%%content%%
[[/div]]

==========

content {2}

This is the default content {2 } for the template. When a new page in the category "project" is created,
it will automatically be filled with the following text. This area can contain standard WikiDot syntax

When this markup is saved as some-category:_template, all pages from the some-category will be combined with the template during rendering.

Content of the page will be substituted into the %%content%% tag.

This way we can add global headers, side bars, navigation elements, modules and comment boxes to the template and the viewed page will automatically have it.

==========

content {3}

This is the default content {3 } for the template. When a new page in the category "project" is created,
it will automatically be filled with the following text. This area can contain standard WikiDot syntax

an example of a template:

[[div style="float:right; width: 200px; border: 1px solid #999; margin: 10px;"]]
%%content{1}%%
[[/div]]

%%content{2}%%

[[table]]
[[row]]
[[column]]
%%content{3}%%
[[/column]]
[[column]]
%%content{4}%%
[[/column]]
[[/row]]
[[/table]]

==========

content {4}

This is the default content {4 } for the template. When a new page in the category "project" is created,
it will automatically be filled with the following text. This area can contain standard WikiDot syntax

Splitting allows you to create sections in the page and manipulate them separately in the template.
Sections are separated by a series (4 or more) "equals" characters and are referred to as %%content{X}%% in the template.

You can access them in any order within the template.

Using this you can easily create advanced layouts (like multicolumn, multi-navigation etc.) and make editing and maintenance much easier.

==========

Unless otherwise stated, the content of this page is licensed under Creative Commons Attribution-ShareAlike 3.0 License