Re: ESCAPE=XML

Mathew Robertson <[email protected]>
Newsgroups gmane.comp.lang.perl.modules.html-template
Organization Nielsen//NetRatings
Message-ID <[email protected]>
Hi Sam,

The highly modified version of H::T that I use, does contain an 
extensible ESCAPE plugin mechanism - main features:
- users can plugin their own ESCAPEs by deriving from H::T::ESCAPE
- ESCAPE modules are loaded at parse-time
- extra escaping modules:
  DOUBLE_QUOTE - which simply puts double quotes around the TMPL_VAR
  STRIP_NEWLINE - does as it says

The only items that I haven't specifically addressed in the escape-loader:
- I havent tested it against H::T::Expr 0.07 yet...
- the path that the modules loaded from; the current implementation does:
    eval "use HTML::Template::ESCAPE::${escape};";
  This has the effect that user-defined modules need to located in the 
system-directories rather than user-directories (which should be an easy 
fix)

It shouldn't be too much work to send a patch...
Mathew

Sam Tregar wrote:
> On Wed, 26 Apr 2006, Jim Spath wrote:
>
>> Just joined the list... excuse me if this has been posted before, but I
>> didn't find a good way to search the mailing list archives.
>>
>> I use HTML::Template for XML templates frequently, and think that
>> ESCAPE=XML would be a useful addition.  So far as I know HTML escaping
>> and XML escaping are slightly different.
>
> Patches welcome.  I'd take it either as a patch adding just these
> escapes or as a system allowing users to plugin new escape code (which
> others have asked for before).
>
> -sam
>
>
> -------------------------------------------------------
> Using Tomcat but need to do more? Need to support web services, security?
> Get stuff done quickly with pre-integrated technology to make your job 
> easier
> Download IBM WebSphere Application Server v.1.0.1 based on Apache 
> Geronimo
> http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
> _______________________________________________
> Html-template-users mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/html-template-users


-------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.