At 11:26 Uhr +0200 27.7.2000, Darko Krizic wrote:
>Newly I did something with Enhydra (Java Servlets) and they have a pretty
...
>Does anybody know something similar for Perl?

I have lately written my own templating scheme, which is part of my
framework running on top of fastcgi (including transparent session
handling, too; see http://testwww.ethz.ch/eile/). Some days ago I looked at
Enhydra, too, and found it very similar to my approach (in the idea, not
the implementation).

Some words about my approach:
- it uses '$var' style variable substitution, curly quotes to markup parts
to be accessed as a whole, and additionally it offers methods to access
table rows, and to fill in form fields (which are recognized by the 'name'
attribute).
- additionally it offers some 'high level' methods, like filling a table
and reordering columns on the fly, or automatically copy all params from a
previous form post into the template again (i.e. for showing the user a
form again 'you have made a mistake .. please post again').
- it mainly uses perl regexps to fill in the data (exception: the table
handler compiles perl code on the fly, which makes it very fast). It's
really fast enough for me.
- it handles automatic html escaping where needed (with some possibility to
customize)
- all relevant links are rewritten automatically to include the session id
(transparent URL rewriting)

The framework is based on fastcgi, and the Html.pm module is in some points
integrated to the whole thing (sessions, caching). Contact me if you really
want to port it..

I wrote my own thing because I was too impatient to learn the details of
Apache::ASP.. :-) (and when I started my development mod_perl was not that
wide spread like today, fastcgi was promising)
The only thing I miss currently is a smart way to map variables to the
template parts so I don't handle dozens of variables or hash fields all the
time. (Some module/class to provide a simple  way of
database--application--template data traffic.)

Christian.


Reply via email to