<wt:node/>
Description
Render a node from the wt database. The node is specified by either the source and type or the guid. If a source is given, the node will be created in edit mode if it doesn't existAttributes
| [source] |
The path to the containing element in the wt tree. Either relative to the current page, or an absolute path |
| [type] |
The node type of the node |
| [guid] |
The guid of the node |
| [path] |
a relative or absolute path to the node |
| [create="yes"] |
set to "no" to not create the node automatically |
| [template] |
the template to use to render the node |
Examples
Relative path (source does not start with a slash)
<wt:node type="General" source="Header">
<wt:editable>
<h2>[wt:Heading]</h2>
<p>[wt:Text]</h2>
</wt:editable>
</wt:node>
in edit mode, this will create a node of type 'wtNode' called 'Header' under the current page and then a node underneath 'Header' of type 'General'
Absolute path (source starts with a slash)
<wt:node type="General" source="/Data/News">
<h2>[wt:Heading]</h2>
<p>[wt:Text]</p>
</wt:node>
this will display the first child of /Data/News which is of type 'General'
Guid specified
<wt:node guid="[wt:wt.request.guid]">
<h2>[wt:Heading]</h2>
<p>[wt:Text]</p>
</wt:node>
this will display a node whose guid is specified by the query string
Path - display the node underneath the current page whose name is 'Articles'
<wt:node path="Articles">
<h2>[wt:Name]</h2>
</wt:node>