> Which TT version are you using.
>
> I get the following with:
>
> [% PERL %]
>
> my $x = <<BAR;
> foo
> Lets put some long text here.
> Hrm
> baz
> BAR
>
> print $x;
>
> [% END %]
>
> It caches the following:
>
>     $output .=  "\n\nmy \$x = <<BAR;\nfoo\nLets put some long text here.
> \nHrm\nbaz\nBAR\n\nprint \$x;\n\n";
>
> That is using TT version 2.14.  So it appears to be fixed in recent
> versions.
>
> If you are using a recent version - what parameters are you initializing
> TT  with?
I am using 2.15, but got the same with 2.14 I think...

I have just tried this (similar problem):

[% SET a = "
adsf
adsf
"
%]

Gives me:

    $stash->set('a', '
    adsf
    adsf
    ');
    $output .=  "\n\n";

Once again the whitespaces...

Here is how I init the stuff (it is a bit complicated as it sits in the
middle of my perl application server...)

use Template;
$Template::Config::STASH = 'Template::Stash::XS';

our $TCONFIG = {
        'COMPILE_EXT'   => '.comp',
        'EVAL_PERL'     => 1,
        'ABSOLUTE'      => 1,
};
$TCONFIG->{'INCLUDE_PATH'} = $DOCROOT;
$TCONFIG->{'COMPILE_DIR'} = "$BASEPATH/compiled";
$TCONFIG->{'INTERPOLATE'} =
$GCONF->{'general'}->{'template'}->{'interpolate'};

$TEMPLATE = Template->new($TCONFIG);


I have:
- v5.8.8 built for i386-linux-thread-multi
- 2.6.18-1.2798.fc6 #1 SMP i686 i686 i386 GNU/Linux



- Csongor




_______________________________________________
templates mailing list
[email protected]
http://lists.template-toolkit.org/mailman/listinfo/templates

Reply via email to