Re: [SLUG] Re: language jihad
Angus Lees was once rumoured to have said: \begin{Crossfire} Mason [aka HTML::Mason] is one of the two `embeded perl' systems for mod_perl. The other one is EmbPerl. [snip] HTML::Embperl is similar (in goal) to the others, but: To be fair to Mason, I'm going to compare against Gus' comments. already has completely integrated sessions (you just access the magic %fdat hash, and it creates/tracks/stores/retrieves a session for you) This aspect of Mason is both good and bad - there is no automagical session handling. However, the positive side is that you can roll your own, and decide when and how its triggered. automatically parses certain HTML tags, to (eg) automatically iterate over rows/columns in tables, set default form values, automatically switch from HTML-escaping to URL-escaping of output, etc. Most of these can be achieved using simple perl constructs with existing modules in Mason. can do a full component-based design of your pages, and override pieces in subtrees, etc. each page only has to contain the unique content, no boilerplate include header/footer statements. This is actually the same as Mason. Mason uses a component model too, and the autohandler provides your for all template - furthermore, autohandlers are invoked recursively up the tree so you can nest functionality without replicating then functionality of autohandlers further up the tree. keeps a log of the request (when debugging is enabled), and adds hyperlinks at the top of the page, so you can see the evaluation and hyperlink to code lines. I'd imagine that Mason would have similar features, but I've never used them. can interactively run pages (from a wrapper perl script) in the perl debugger, and it shows you the right source lines, etc. can't do this yet in Mason AFAIK. the backend parser is written in C, so its quite a bit faster than mason (see: http://www.chamas.com/bench/index.html) Its not like Mason's speed is a problem for SLUG anyway. :P~ Mason tries to make up for its performance caching the Mason-Perl compiled pages - which remain cached in memory when mod_perl requests them. it doesn't try and hide the perl, so you can do everything you're used to in normal perl, with very little changes. (this was one of my main reasons for choosing it over alternatives) Mason also uses straight perl - Mason pages are compiled back to perl and are cached in that form, just like JSP pages inside most JSP environments. embperl 2.0 (still alpha) supports multiple syntaxes (including XML, SSI, Apache::ASP, and straight perl CGI), completely tunable caching, etc. I can't see why such a thing would be so important. Mason also has built in data and response caching which operates over components, not just pages. Backends can be coded as perl modules, called from inside of Mason for those who are into templating systems, otherwise you can code in-place for those who prefer embedded-code solutions. Furthermore, Mason is fully documented (see masonhq.com), and is also moderately widely used. Another cute feature is %filter which lets you run a content filter over components that have just executed - this can lead to some *very* cute solutions to problems [it makes navigation bars which show the current page that much easier to implement]. Mason also features dhandlers, which are invoked when a document can't be found for a given URI, allowing you to create virtualised content trees from data-sources easily. Anyhows, the documentation is a suggested read since it covers the feature-set better than I can. C. -- --==-- Crossfire | This email was brought to you [EMAIL PROTECTED] | on 100% Recycled Electrons --==-- -- SLUG - Sydney Linux User Group Mailing List - http://slug.org.au/ More Info: http://slug.org.au/lists/listinfo/slug
Re: [SLUG] Re: language jihad
quote who=Ben Leslie I thknk that this is fixed in 2.1 where nested scopes are implemented. One of the more amusing things about Python: from __future__ import nested_scopes Unfortunately, for everyone out there with code relying on this not being implemented, Python 2.2 will not have a __past__ directive. :) Here's the PEP: http://www.amk.ca/python/2.1/index.html#SECTION00040 - Jeff -- Australians don't dislike Americans, we just dislike the sight, sound and thought of them. -- SLUG - Sydney Linux User Group Mailing List - http://slug.org.au/ More Info: http://slug.org.au/lists/listinfo/slug
[SLUG] Re: language jihad
\begin{Jamie Wilkinson} This one time, at band camp, getadog said: To list a few good points of zope, revision control, it will allow multiple people to work on the site at once. It will allow you to undo mistakes. cvs allows multiple people to work on the site, provides revision control. vims 'u' command allows you to undo mistakes. and there's always W3C's Distributed Authoring and Versioning standard. see mod_dav -- - Gus -- SLUG - Sydney Linux User Group Mailing List - http://slug.org.au/ More Info: http://slug.org.au/lists/listinfo/slug
[SLUG] Re: language jihad
\begin{Terry Collins} Jeff Waugh wrote: into the Windows glove just like VBScript, ECMAScript, PerlScript and at least I didn't use fowl language {:-). Nor did I point out the obvious *nix language LISP! Which leads to emacs. if you use W3 as your browser ((x)emacs' web browser), you can have 'script language=elisp' in your web pages ;) -- - Gus -- SLUG - Sydney Linux User Group Mailing List - http://slug.org.au/ More Info: http://slug.org.au/lists/listinfo/slug
Re: [SLUG] Re: language jihad
On Tue, 01 May 2001, Angus Lees wrote: \begin{Ben Leslie} Python (www.python.org) is a nice object oriented language which I find quite good for most of my needs. I'll outline pros and cons below. Cons: no closures (proper anonymous functions) (yet) I thknk that this is fixed in 2.1 where nested scopes are implemented. http://www.amk.ca/python/2.1/index.html Cheers, Benno -- SLUG - Sydney Linux User Group Mailing List - http://slug.org.au/ More Info: http://slug.org.au/lists/listinfo/slug
[SLUG] Re: language jihad
\begin{Ben Leslie} Python (www.python.org) is a nice object oriented language which I find quite good for most of my needs. I'll outline pros and cons below. Cons: no closures (proper anonymous functions) (yet) if it wasn't for CPAN, i'd probably use python. (although the python crowd seem to be a little confused over licenses, unlike the perl world, where *everything* is either the perl license or GPL) -- - Gus -- SLUG - Sydney Linux User Group Mailing List - http://slug.org.au/ More Info: http://slug.org.au/lists/listinfo/slug
[SLUG] Re: language jihad
\begin{Crossfire} Mason [aka HTML::Mason] is one of the two `embeded perl' systems for mod_perl. The other one is EmbPerl. others include eperl, template toolkit, Apache::ASP and more the whole php/asp lets put code amongst HTML! thing is hardly a unique idea. HTML::Embperl is similar (in goal) to the others, but: already has completely integrated sessions (you just access the magic %fdat hash, and it creates/tracks/stores/retrieves a session for you) automatically parses certain HTML tags, to (eg) automatically iterate over rows/columns in tables, set default form values, automatically switch from HTML-escaping to URL-escaping of output, etc. can do a full component-based design of your pages, and override pieces in subtrees, etc. each page only has to contain the unique content, no boilerplate include header/footer statements. keeps a log of the request (when debugging is enabled), and adds hyperlinks at the top of the page, so you can see the evaluation and hyperlink to code lines. can interactively run pages (from a wrapper perl script) in the perl debugger, and it shows you the right source lines, etc. the backend parser is written in C, so its quite a bit faster than mason (see: http://www.chamas.com/bench/index.html) properly hooks into the mod_perl cleanup stage, so writing-back database entries/session, cleaning up the perl environment, etc happens *outside* the HTTP critical path it doesn't try and hide the perl, so you can do everything you're used to in normal perl, with very little changes. (this was one of my main reasons for choosing it over alternatives) embperl 2.0 (still alpha) supports multiple syntaxes (including XML, SSI, Apache::ASP, and straight perl CGI), completely tunable caching, etc. (ps. i'm the libhtml-embperl-perl.deb maintainer) -- - Gus -- SLUG - Sydney Linux User Group Mailing List - http://slug.org.au/ More Info: http://slug.org.au/lists/listinfo/slug