Slash Boxes
NOTE: use Perl; is on undef hiatus. You can read content, but you can't post it. More info will be forthcoming forthcomingly.

All the Perl that's Practical to Extract and Report

The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
More | Login | Reply
Loading... please wait.
  • I don't really see why this is bad (feel free to show me the errors of my ways, heh). Why should whether PHP behaves like Perl have any bearing on its merits as a language? I'm always happy to listen to the arguments against PHP, and there are some good ones, but this seems a bit trivial to me.

    In addition, PHP's implementation makes more sense in this case, especially since it is consistent with other PHP functions. If explode() returns an array, I can be confident that I always get an array, and the eleme

      • I'm always happy to listen to the arguments against PHP...

      And, I'm willing to listen to arguments for PHP. What does PHP buy you that you can't get with things like plp [] or the various templating systems?

      I've never done any PHP myself, but those I know who have used it are constantly frustrated by the limitations and often resort to Perl on the backend. Why have two languages? The maintenance and support nightmares multiply in that kind of environment, from what I can see.

      Maybe PHP had a place once up

      • by shiflett (3841) on 2004.01.06 19:34 (#27091) Homepage Journal

        I'm not one to ever argue for PHP over mod_perl or the other way around. To me, both are winners, and you should go with what you're familiar with. My arguments against languages involve all of the stuff that begins with J and all of the stuff made by Microsoft. :-)

        Here are some reasons why PHP is so popular (mod_perl shares some but not all of these features):

        1. It's an open source, server-side scripting language made for creating Web applications.
        2. The syntax is very similar to C, so for many programmers, there is practically no time required to learn the syntax.
        3. It is extremely easy to learn. Because you can embed it in HTML, you can start with something as simple as <? phpinfo(); ?> in the middle of some HTML to get started.
        4. It's Web server and OS agnostic, so everyone can try it out regardless of what platform they're running.
        5. It has hooks into just about every Web server and database imaginable.
        6. Because it was designed specifically for the Web, its native features revolve around such needs. Things like session mechanisms are built into the core rather than available as userland modules.
        7. In Apache, it only hooks into the content generation phase, so it's safer to run in multi-user environments. As a result, a large majority of Web hosts offer PHP (combine this with point 3)

        You can point to sites like Ticketmaster for mod_perl, and you can point to sites like Yahoo for PHP. Anyone who can't get the job done in either language obviously doesn't know the language very well. :-)

        • Here I was all set to start a big religious flame war over Perl vs. PHP and you douse it with a cold bucket of reasonableness and solid justification.

          Couldn't you at least say something nasty about Perl?