This queue is for tickets about the HTML-Template-Compiled CPAN distribution.
Maintainer(s)' notes
Note: there is a bug with caching and TMPL_INCLUDE_VAR since 0.97_004 until 0.98. either use an earlier version or upgrade to 0.98_001. Another workaround is to precompile all templates to file_cache_dir. The bug happens when including a template via INCLUDE_VAR and the template is not yet compiled or has changed.
I'm sorry if the change about aliases came quite unannounced. I didn't expect any problems since dollar signs are not allowed in template vars, but I heard from at least one case where people were doing exactly this.
Please do not use unallowed characters in template vars.
Allowed are (from the HTML::Template::FAQ): Numbers, letters, '.', '/', '+', '-' and '_'.
This should work in HTML::Template::Compiled::Classic.
in HTML::Template::Compiled you should be only using numbers, letters and _.
The dot, for example, is special. If you need to get a hash key from the template parameters with special charcaters, you can try <tmpl_var _.$var$name$with$dollars >
There will be a workaround in the next version:
local $HTML::Template::Compiled::Compiler::DISABLE_NEW_ALIAS = 1;
Please report any bug you find.
The code is now hosted on https://github.com/perlpunk/HTML-Template-Compiled
If you have a bug report, you can also post it there in the "Issues" section.
In the bugreport, please include, if possible, the module version, perl version and a testcase that reproduces the error; that makes it easier to find the bug.
The issue with not reloading includes of includes should be fixed in version 0.95_003.
If you have any problems though please report!
Using query() and the dot syntax might not work together always. If you have a tmpL_var name="..foo" (going up the stash one level) the var foo is not detected and will not be reported by the query() function. Since the dot syntax is for dereferencing hashes and method calls the query function might not make sense anyway. I believe it is a bad idea to let the program do things if the template is using a certain variable.
Thanks!
Owner: |
Nobody in particular
|
Requestors: |
STEFFENW [...] cpan.org
|
Cc: |
|
AdminCc: |
|
|
Severity: |
Important |
Broken in: |
0.86 |
Fixed in: |
0.97_004 |
|
Tue Jul 03 05:10:23 2007
STEFFENW [...] cpan.org - Ticket created
use HTML::Template::Compiled;
my $htc = HTML::Template::Compiled->new(
path => /template/',
filename => subdir/file.htc,
tagstyle => [qw(-classic +asp)],
);
__END__
file /template/subdir/file.htc
<%INCLUDE subdir/i.htc%>
subdirc/file.htc' not found at /opt/perl-
5.8.8/lib/site_perl/5.8.8/HTML/Template/Compiled/Compiler.pm line 630
***
File "/template/subdir/subdir/i.htc" was found but not
file "/template/subdir/i.htc".
The same example is working with HTML::Template.
Message body not shown because it is not plain text.
Thu Jul 05 07:56:16 2007
TINITA [...] cpan.org - Correspondence added
On Di. 03. Jul. 2007, 05:10:23, STEFFENW wrote:
Show quoted text> subdirc/file.htc' not found at /opt/perl-
> 5.8.8/lib/site_perl/5.8.8/HTML/Template/Compiled/Compiler.pm line 630
Show quoted text> The same example is working with HTML::Template.
thanks for the report.
if this works in HTML::Template i understood search_path_on_include
wrong.
it says:
search_path_on_include - if set to a true value the module will search
from the top of the array of paths specified by the path option on
every <TMPL_INCLUDE> and use the first matching template found. The
normal behavior is to look only in the current directory for a template
to include. Defaults to 0.
so i'm trying to find out the exact correct behaviour of HTML::Template
before i make a bugfix.
Thu Jul 05 07:56:21 2007
The RT System itself - Status changed from 'new' to 'open'
Tue Jul 31 03:47:15 2007
TINITA [...] cpan.org - Status changed from 'open' to 'stalled'
Sat May 19 16:16:45 2012
TINITA [...] cpan.org - Correspondence added
I finally had a closer look, since the documentation of HTML::Template
wasn't really clear.
Now it seems it's working like in HTML::Template. I added a comment in
the docs and also added a third value for search_path_on_include that
searches for the file in the specified paths *and* the current template
directory.
will be in the next version.
Sat May 19 16:16:46 2012
The RT System itself - Status changed from 'stalled' to 'open'
Mon May 21 04:40:06 2012
TINITA [...] cpan.org - Fixed in 0.97_004 added
Sun Jul 26 07:10:03 2015
TINITA [...] cpan.org - Status changed from 'open' to 'resolved'