Perl & PHP

phpnutphpnut Junior MemberShared Hoster
What are the main differences between Perl and PHP?
My ongoing projects...
www.naturesmagazine.com
www.energyreform.org *new domain*
www.photographyavenue.com
----
You may also remember me as imnewtophp...

Comments

  • AeriffAeriff Junior Member Shared Hoster
    To be Honest, I couldnt tell you.. Someone else who knows might be able to tell you, but you cant go wrong with a Google search ;)
  • NuvoNuvo Forum Leader VPS - Virtual Prince of the Server
    PHP is a nicer language to program with in my opinion as it's built for the web (though you can do other things with it).
    With Perl, you need to use modules to get some functionality (such as sessions) and as it's not primarily a web language, you end up using it through CGI 90% of the time.
    Neither is incredibly bad and both have their pitfalls (Perl is older and very flexible, but needs modules for some things).
    Perl has had some degree of OOP support for longer than PHP, which only got some degree of real OOP support in version 5 (classes in PHP4 give it some OOP like functionality, but you have to make the classes yourself or grab them from the net) and as web scripting matures, OOP is becoming more important.
    Neither language is fully OOP and both support procedural programming.
    If OOP is important, Ruby might be worth a look.

    In my view, web application frameworks are likely to become more commonplace and this is where Ruby shines over all others.
    Rails is far more advanced than PHP frameworks, including the one ZEND is working on.
    Frameworks are good not because they make web development easier for newbies, but because they make tasks which are often annoying such as database managment simple.
    If you've got a framework to handle databases, it's much easier than worrying about supporting mySQL, Postgres, SQLite, Oracle, DB2 and other SQL server variants and if you can easily target more types of systems, you can get more users.
    It remains to be seen though if Rails will steal PHP's thunder, or if PHP5 will keep it going with newer features such as better Object Oriented Progamming support and a decent framework.
    PHP, CSS, XHTML, Delphi, Ruby on Rails & more.
    Current project: CMS Object.
    Most recent change: Theme support is up and running... So long as I use my theme resource loaders instead of that in the Rails plug-in.
    Release date: NEVER!!!
Sign In or Register to comment.