Perl and PHP can coexist - even on a single website.
[snip]
> PHP is based on a model of a-file-is-a-page. It's easy to set up a
> moderately useful dynamic website using PHP due to its shallow learning
> and implementation curves, but when you're done, what you've got is a
> website with an enumerated set of states, each of which corresponds to a
> file.
>
[snip]
>
> In short, if your dynamic site can be described as a set of screen
> shots _without_ notations like `this toolbar only appears if the user has
> selected such-and-so preference' or `draw this as a frameset unless the
> user has browser XYZ', and you like PHP, then there's nothing wrong with
> PHP. If you really sit down and think about the future, though, you
> probably can't promise that your site will always be that way.
>
> And even if you can promise that, you might want to think about
> Template Toolkit or HTML::Mason.
I am running a site/resource which uses both PHP and Perl - for most users
and the activities in which they are involved (editing pages, posting new
documents, adding to BBS etc), the PHP page/file model is fine. Beginning
users also find PHP easier to use and can conceptualise the way the pages
are constructed (from html, includes and code blocks) without too much
difficulty.
When it comes to looking in more detail at data at a 'finer' level of
componentisation, as is needed when we come to analyse the data submitted
by users, for example, I switch to Perl with Template Toolkit.
But the key is using them together - the data is XML files (vcards, dublin
core, IEEE learning object model). IF all that is needed is a simple 'page
retrieval' , PHP is adequate - and simple enough for less experienced users
; if I want to do something more complicated, then I have the
XML::Parser-based Perl parsers to use (mainly Twig). The XML stays the
same, after all ... as do .inc files for headers, footers, sidebars - which
get called in from mainly HTML pages using PHP or using Perl and TT.
Patrick Carmichael
Lecturer in IT and Education
School of Education
Bulmershe Court
University of Reading
Reading RG6 1HY