Template Macro
This is the equivalent of the C preprocessor include directive : the result is a copy of the script passed as argument, into your script.Usage
#template($relativeURL)
Parameters definition
The path to the script you want to include. The path is relative to the directory of your skin. For example, if you are using the albatross skin, and have installed XWiki using the installer with default settings, the skin path will be :C:\Program Files\XWiki Enterprise\webapps\xwiki\skins\albatross
myscript.vm you want to include, and that script is located in a folder mydir inside the skin folder,
C:\Program Files\XWiki Enterprise\webapps\xwiki\skins\albatross\mydir\myscript.vm
#template("mydir/myscript.vm")Example
#template("comments.vm")Result
Comments for TemplateMacro
VincentMassol
| 14.11.2007 at 09:04 PM
Jean-Vivien, what do you think of documenting the TemplateMacro here instead of in the "Include on Velocity" page and modify "Include on Velocity" to refernce the different macros in the code zone?
It would be nice if all the macros could be documented in the Code Zone.
Thanks!
Version 7.1 last modified by VincentMassol on 19/06/2008 at 22:13
Document data
Comments: 1
| 14.11.2007 at 09:04 PM
Jean-Vivien, what do you think of documenting the TemplateMacro here instead of in the "Include on Velocity" page and modify "Include on Velocity" to refernce the different macros in the code zone?
It would be nice if all the macros could be documented in the Code Zone.
Thanks!
Attachments:
No attachments for this document