Dear Wiki user,

You have subscribed to a wiki page or wiki category on "Cocoon Wiki" for change 
notification.

The following page has been changed by FHersey:
http://wiki.apache.org/cocoon/PerlScriptGenerator

------------------------------------------------------------------------------
  ===  Download ===
  Download the bsfperl.jar from [http://bsfperl.sourceforge.net] and put it 
into the WEB-INF/lib directory of your webapp. If you want to rebuild your 
Cocoon you should copy it also to the lib/local directory of your Cocoon 
sources, otherwise the JAR will be lost after the build.
  
- ===  Sitemap entry ===
+ === Add the "script" generator to your sitemap and register the BSFPerl 
engine with BSF ===
+ {{{
+ <map:generators>
+   ...
+   <map:generator name="script"
+       src="org.apache.cocoon.generation.ScriptGenerator">
+     <add-languages>
+       <language name="perl" src="net.sourceforge.bsfperl.PerlEngineImpl">
+         <extension>pl</extension>
+       </language>
+     </add-languages>
+   </map:generator>
+ </map:generators>
+ }}}
+ 
+ ===  add a match which calls the script generator to your sitemap ===
  {{{
  <map:match pattern="hello.pl">
    <map:generate src="hello.pl" type="script">
@@ -15, +30 @@

  
  ===  Perl script (hello.pl) ===
  {{{
- 
  use strict;
  
  # 

Reply via email to