type
attribute of the script
element. For example: <script type="application/groovy"> public int getValue(){ return 10; } </script>
script
element has a type
attribute, the framework will use this MIME type to get the language of the scriptscript
element has no type
attribute but it is an external script, the framework will use the extension of the script file to infer the language of a scripttype
attribute, the framework will assume that it is a Javascript scripttype
attribute:<script type="text/groovy"> public int clicked() { context.echo("Clicked!"); } </script>
<script> function clicked() { print("Clicked!"); } </script>
<script src="myScript.groovy" />
<script> public int checked() { context.echo("checked!"); } </script>The framework will show the following exception:
Copyright 2008-2020 Herve Girod. All Rights Reserved. Documentation and source under the LGPL licence