Loading…
None
String updated in the repository |
|
None
Source string changed |
|
Loading…
None
String updated in the repository |
|
None
Source string changed |
|
== Scripts ==
=== 1.0 Scripts ===
{{info}}In XWiki Syntax 1.0 it was possible to enter Velocity scripts anywhere directly in the page. This can lead to issues for example when the user was involuntarily entering Velocity content. It is also performance hungry for pages not requiring Velocity content. There are several other technical limitations. Same goes for entering Groovy scripts.{{/info}}
|=Feature|=XWiki Syntax 1.0
|Velocity script|((({{{
#set ($var = "whatever")
}}})))
|Groovy script|((({{{
<%
def var = "whatever"
%>
}}})))
=== 2.0 Scripts ===
{{info}}XWiki [[supports several scripting languages>>https://www.xwiki.org/xwiki/bin/view/Documentation/DevGuide/Scripting/]].{{/info}}
|=Feature|=XWiki Syntax {{velocity}}$crtSyntaxVer{{/velocity}}
|Velocity script|((({{{
{{velocity}}
#set ($var = "whatever")
{{/velocity}}
}}})))
|Groovy script|((({{{
{{groovy}}
def var = "whatever"
{{/groovy}}
}}})))
== Skript ==
=== 1.0 Skript-koder ===
{{info}}I XWiki Syntax 1.0 var det muligt at indsætte Velocity-kode direkte i siden. Dette kan føre til problemer, når f.eks. brugeren ved et uheld indsætter Velocity-kommandoer. Det overbelaster også sider, der ikke har brug for Velocity-indhold. Der er andre tekniske begrænsninger. Det samme gælder Groovy-kode.{{/info}}
|=Feature|=XWiki Syntax 1.0
|Velocity script|((({{{
#set ($var = "whatever")
}}})))
|Groovy script|((({{{
<%
def var = "whatever"
%>
}}})))
=== 2.0 Skript-koder ===
{{info}}I XWiki Syntax {{velocity}}$crtSyntaxVer{{/velocity}} skal Velocity-koder ved at bruge ###velocity### makroer. Det samme gælder for Groovy-koder.{{/info}}
|=Feature|=XWiki Syntax {{velocity}}$crtSyntaxVer{{/velocity}}
|Velocity script|((({{{
{{velocity}}
#set ($var = "whatever")
{{/velocity}}
}}})))
|Groovy script|((({{{
{{groovy}}
def var = "whatever"
{{/groovy}}
}}})))