aw schriftzug.png aw logo 60x60.png

%PERL{"perl expression"}%

  • Expands to the result of the perl expression, evaluated in a Safe container.
%PERL{topic="topic name"}%
  • Expands to the result of the perl program contained between %CODE{}% and %ENDCODE% in the named topic.
  • You can only use a subset of perl, as defined in the Foswiki configuration.

Examples

If the plugin is installed, the text after 'expands to' will show the result of the example.
  • %PERL{"'A String'"}% expands to A String
  • %PERL{"101 - 59"}% expands to 42
  • %PERL{topic="System.VarPERL"}% expands to 100

Perl code used for this example:
%CODE{"perl"}%
my $x = 99;
$x = $x + 1;
return $x;
%ENDCODE%
Topic revision: r1 - 2010-11-11, UnknownUser
This site is powered by FoswikiCopyright &© by the contributing authors. All material on this site is the property of the contributing authors.
Ideas, requests, problems regarding Wiki? Send feedback