Perl or PHP for web work ?

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Bob

    Perl or PHP for web work ?

    [Crossposted, looking for experts from both for discussion.
    Not an argument, just a discussion :-]

    As the title says, I'm looking to assess the advantages and
    disadvantages of Perl vs. PHP for web (cgi) programming. I'm
    a newbie at Perl, and a true novice at PHP but I have lots of
    other programming in languages and scripting (eg. ASP) experience.
    I know that Perl has the historical advantage in volume and
    resources. However, PHP seems to be a strong "up and comer" and
    is widely available on web servers.

    I think Perl has far greater capabilities as a programming language.
    However, it is also _so_ flexible in it's constructs that it is a
    little intimidating for someone new to the language. It seems to allow
    so many interesting variations that it is at time overwhelming.
    (Multiple variables to the left of the assignment statement ? Holy
    $hit! :-) I know I don't have to use all the variations, but I find
    them in other programmers code, so I'll need to know them.

    PHP seems to be a lot simpler. That's an advantage when starting out.
    But, does PHP run out of power? I don't know enough of it to
    tell at this point. So, I'm looking for comments.

    Most of what i plan to do is fairly basic web work... dealing with
    data in an out of databases, simple business calculations, etc.
    Thoughts on which is a better course to pursue ?

    Thanks,
    Bob




  • Phil Roberts

    #2
    Re: Perl or PHP for web work ?

    With total disregard for any kind of safety measures Bob
    <none@spammenev er.com > leapt forth and uttered:

    This topic is so old its practically fossilised.
    [color=blue]
    > Most of what i plan to do is fairly basic web work... dealing
    > with data in an out of databases, simple business calculations,
    > etc. Thoughts on which is a better course to pursue ?
    >[/color]

    Use PHP. PHP was designed for the web and Perl, for all its
    flexibility and power, was not.

    Besides, for your purposes there really isn't anything that Perl
    can do that PHP can't do equally as well if not better.

    --
    There is no signature.....

    Comment

    • James

      #3
      Re: Perl or PHP for web work ?

      On Tue, 19 Aug 2003 15:40:54 -0500, Phil Roberts
      <philrob@HOLYfl atnetSHIT.net> scrawled:
      [color=blue]
      >With total disregard for any kind of safety measures Bob
      ><none@spammene ver.com > leapt forth and uttered:
      >
      >This topic is so old its practically fossilised.
      >[color=green]
      >> Most of what i plan to do is fairly basic web work... dealing
      >> with data in an out of databases, simple business calculations,
      >> etc. Thoughts on which is a better course to pursue ?
      >>[/color]
      >
      >Use PHP. PHP was designed for the web and Perl, for all its
      >flexibility and power, was not.
      >
      >Besides, for your purposes there really isn't anything that Perl
      >can do that PHP can't do equally as well if not better.
      >[/color]
      I use both Perl and PHP extensively for work and hobbies, there are
      certain things that PHP isn't quite there yet with - e.g. handling
      XHTML documents ( none of the standard PHP XML modules can cope
      with HTML's character entities ); handling POST requests (except with
      the massive overhead of cURL )... It's also an extremely verbose
      language in comparison to the beautiful compactness of Perl...

      It's horses for courses, I would try and use PHP for mainly web-based
      applications - but I still find it easier to use Perl in about 10% of
      these cases and in more general data munging.

      At work I have to use Perl as we leverage a large Perl API for webpages,
      with many quite complex mod_perl handlers - yet another things you
      can't do with PHP.

      J

      Comment

      Working...