Version 13.1 by Thomas Mortagne on 2011/10/27 18:01
![]() | Copy the script passed as argument into your script |
Type | Doc (Velocity Macro) |
Category | |
Developed by | Unknown |
Rating | |
License | Unknown |
Table of contents
Description
This is the equivalent of the C preprocessor include directive.
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
So if you have a skin script called 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
you will use the following Velocity instruction in your scripts :
#template("mydir/myscript.vm")
Example
#template("comments.vm")