Python Macro

The macro adds the ability to write scripts in Python in wiki pages. This is a shortcut for the Script Macro equivalent to {{script language="python"}} to execute python scripts based on any JSR-223 Python provider like Jython.

Usage

{{python}}
print "Hello World"
{{/python}}

Parameters Definition

NameOptionalAllowed valuesDefault valueDescription
languageyesthe identifier of the JSR 223 engine Indicates which engine to use to execute the provided script. 
outputyestrue/falsetrueIndicates the output result has to be inserted back in the document.
wikiyestrue/falsetrueindicates if the result of the script execution has to be parsed by the current wiki parser. If not, it is put into a verbatim block.
jarsyescomma-separated list of JARs that will be added to the script execution class loadernone

Example

{{python}}
print "Hello World"
{{/python}}

Related Pages

Search this space

 

Most popular tags

Failed to execute the [groovy] macro
  1. access rights
  2. activity stream
  3. annotation
  4. attachment
  5. comment
  6. Document Tree Macro
  7. export
  8. Extension Manager
  9. Flamingo skin
  10. global user
  11. Groovy event listener
  12. group
  13. nested page
  14. search
  15. skin
  16. syntax
  17. user
  18. user profile
  19. velocity macros
  20. wiki
  21. wysiwyg
  22. XWiki Applications
  23. xwikiattachment_archive table
  24. xwikiattachment table
  25. xwikiattrecyclebin table
  26. xwikiproperties table

[Display all tags from this space]