Last modified by Simon Urli on 2023/10/10

<
From version < 101.1 >
edited by Vincent Massol
on 2019/05/20
To version < 101.2 >
edited by Vincent Massol
on 2019/05/20
>
Change comment: There is no comment for this version

Summary

Details

Page properties
Content
... ... @@ -71,7 +71,7 @@
71 71  
72 72  Note that by default this makes the content of the macro directly editable in [[the WYSIWYG editor>>https://extensions.xwiki.org/xwiki/bin/view/Extension/CKEditor%20Integration/#HWikiMacros]].
73 73  )))
74 -* The older way to insert the content is by executing the following velocity code in the macro body:(((
74 +* The older way to insert the content is to use the ##xcontext## binding. For example, when using Velocity, you can write the following script in the macro body:(((
75 75  {{code language="none"}}
76 76  {{velocity}}$xcontext.macro.content{{/velocity}}
77 77  {{/code}}
... ... @@ -116,8 +116,6 @@
116 116  
117 117  == Translations ==
118 118  
119 -
120 -
121 121  When your macro is ready, you might want to provide the description of the macro and its parameters in different languages. For that, you need to create a set of translation keys and values (as described [[here>>platform:DevGuide.InternationalizingApplications]]) and then just use the following convention for the keys you add in this storage (no modification is needed on the macro itself, the association of the translations to the macro is done based on a convention of the form of the translation keys):
122 122  
123 123  {{code}}

Get Connected