Begin main content

MasonX::WebApp - Web Applications with Perl OO

Here is a nice way of structuring Web Applications in Perl getting the best of most worlds:

MasonX::WebApp

MasonX::WebApp is basically a query dispatcher that calls a particular method in your WebApp perl module (of the same name as the url) which may then (after doing the real work) pass control to a mason component to render some html output.

It lets you write your app using all your Perl OO goodness and make use of Mason's html ease—all without resulting in a mess of incoherant Mason modules full of code.

The best example is the code for a site by the module Author (Dave Rolsky), you can download it here—I haven't seen 25,000 lines of code that clean for a very long time!

08:34 PM, 14 Jul 2004 by Mark Aufflick Permalink

Apache::Reload considered beneficial

A MasonX::WebApp app would benefit from using Apache::Reload: http://search.cpan.org/~msergeant/Apache-Reload-0.07/Reload.pm

by Mark Aufflick on 07/15/04

Speaking of Perl OO

This is a (somewhat harshly written) thread with a pertinent warning for those carrying some perl-ish practices into OO. http://www.perlmonks.org/index.pl?node_id=219131 Read the comments as well. Basically Abigail is saying that you should be using traditional set and get methods with their own internal variable stores and not dumping all the objects data into a fat hash. I can see the merits of both sides, but I've been bitten by too many problems with misspelt hash keys to argue - the more traditional OO way gets my vote.

by Mark Aufflick on 07/29/04

Add comment