| The <{perl}> Directives
                          Arbitrary perl code can be executed using this directive.
                          
                         
                          It works like perl's evalcommand; the return value from the perl block is
                          inserted into the file, so a perl code block like this: 
                           
                          
	<{perl
	  $_ = '';
	  for my $fruit (qw(apples oranges pears)) {
	    $_ .= " ".$fruit;
	  }
	  $_;
	}>
                        
                        will be replaced with the string " apples oranges pears". Note that the
                        $_variable is declared as local when you enter the perl block,
                        you don't have to do this yourself. 
                        If you don't like the eval style, you can use a more PHP/JSP/ASP-like
                        construct using the perloutdirective, which replaces the perl code text
                        with anything that the perl code prints on the default output filehandle, like
                        so: 
                         
                        
	<{perlout
	  for my $fruit (qw(apples oranges pears)) {
	    print " ", $fruit;
	  }
	}>
                      
                      Note that this is not STDOUT, it's a local filehandle called $outhandle.
                      It is selected as the default output handle, however, so justprintwithout a filehandle name will work. 
                      Also, it should be noted that perlis a little more efficient thanperlout, so if you're going all-out for speed, you should use that. 
                      <{perl}> sections found at the top level of the
                      WebMake file will be evaluated during the file-parsing pass, as they
                      are found.
                      
                     
                      <{perl}> sections embedded inside content chunks
                      or other tagged blocks will be evaluated only once they are referenced.
                      
                     
                      Perl code can access content variables and URLs using the library functions provided.
                      
                     
                      The library functions are available both as normal perl functions in the
                      default mainpackage, or, if you want to write thread-safe or mod_perl-safe
                      perl code, as methods on the$selfobject. The$selfobject is available as a local variable in the perl code block. 
                      A good example of perl use inside a WebMake file can be found in the
                      news_site.wmkfile in the examples directory. 
                      
                     |