in reply to Migrating from PHP to Perl for the web.
An MVC framework such as Catalyst makes extensive use of this. Perl does all the heavy (computational and database) lifting, the template allows you to write your webpages quite easily and an OO-wrapper around your database makes for an easy and consistent access to your data.
At first --and to many a PHP programmer-- this seems unnecessarily complex, but actually it makes for far cleaner code. Changing the data-store is done only in the model-layer (which is mostly just some config-files), the business logic is found in the Perl code in the controllers and the eye-candy for your web-page is found in the view layer of the templates. You will be hard-pressed to maintain such a nice separation of concerns in your PHP-application.
CountZero
A program should be light and agile, its subroutines connected like a string of pearls. The spirit and intent of the program should be retained throughout. There should be neither too little or too much, neither needless loops nor useless variables, neither lack of structure nor overwhelming rigidity." - The Tao of Programming, 4.1 - Geoffrey James
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Migrating from PHP to Perl for the web.
by monarch (Priest) on Dec 01, 2007 at 11:41 UTC |