perl-modperl mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "JupiterHost.Net" <>
Subject Re: mod_perl2 and PHP
Date Sat, 06 Aug 2005 13:55:16 GMT
Thomas Klausner wrote:
> Hi!


> Is it possible and advisable to write the complex part of an application
> (the Controller, if you like) in mod_perl2 and use PHP as a frontend (or
> View) ?
> While I personally prefere Template::Toolkit as a presentation language, the
> project I'm currently getting involved in has quite a lot of PHP-people and
> not that many (read: me) Perl people.

That is a bummer ;)

> So what I thought is: use Perl to implement the rather complex business
> logic, and PHP for rendering (and getting form input to the 'backend').

So Perl does all the real work while eveyone else see's PHP and thinks 
"wow look at how great PHP is"? boo for that!! :)

> But: can I create a datastructure in Perl (in an ResponseHandler) and pass
> it on to PHP running also as an ResponseHandler, but afterwards. Would I
> need to stuff data in ENV? Can I pass complex data structures around? Do I
> have to serialise (to yaml/xml) between Perl and PHP?

I think Storable may be able to be shared between Languages, maybe??
type file or xml but then you add another layer of complexity and 
overhead but if you have to you have to :)

> Or is this a bad idea altogether and I should use a different approach (Like
> forcing everyone to read the Badger)?

I'd do that personally :) They'll be better off in the end to have 
learned about Perl in addition to theri PHP skills.
PHP is cute and all but if it s all they do they'll remain stupid.

View raw message