Help for this page

Select Code to Download


  1. or download this
    my $template = Template->new();
    my $vars = {co_name=>"Foo-Co"};
    ...
    $template->process(\$my_template_string, $vars, \$string);  # stores o
    +utput in $string
    print $string;
    $template->process(\$my_template_string, $vars );  # dumps output to S
    +TDOUT
    
  2. or download this
            $content =~ s/(\$[a-zA-Z0-9\{\'\}_]+)/ eval($vars{$1}) || $var
    +s{eval($1)} || eval($1) /ge;
    
  3. or download this
            $content =~ s/(\$[a-zA-Z0-9\{\'\}_]+)/ eval($temp_vars{$1}) /g
    +e;
            $content =~ s/(\$[a-zA-Z0-9\{\'\}_]+)/ $temp_vars{eval($1)} /g
    +e;