Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

Re^4: Preaching Perl gospel to PHP converts...

by diotalevi (Canon)
on Feb 05, 2003 at 18:17 UTC ( [id://232876]=note: print w/replies, xml ) Need Help??


in reply to Re: Re: Re: Preaching Perl gospel to PHP converts...
in thread Preaching Perl gospel to PHP converts...

PHP is very easy to install. mod_perl is not.
I've seen this asserted before and it always leaves me scratching my head. Can you or someone else elaborate on what is so easy about installing and maintaining PHP? The way I understand it, I have to pick which "modules" I want PHP to use before compiling it. If I want to change those, add new modules or upgrade some then I have to do the ./configure (with scads of options); make; make test; make install dance. At least with perl if I want to upgrade or add DBD::Pg it is separate from the perl core so I'm not forced to do the equivalent of recompiling perl and mod_perl.

The perl dance looks like: download String::Approx, perl Makefile.PL LIB=~/lib && make && make test && make install and then any code that wants to make use of that just says use String::Approx.

Am I just not understanding PHP here or this the supposedly "easy" process? If there is a better way to manage a PHP installation I'd love to hear about it since I can see myself wanting to use PHP occassionally and it'd be good to have a maintenance process that isn't torture.


Seeking Green geeks in Minnesota

Replies are listed 'Best First'.
Re: Re^4: Preaching Perl gospel to PHP converts...
by Anonymous Monk on Feb 05, 2003 at 19:15 UTC
    The way I understand it, I have to pick which "modules" I want PHP to use before compiling it. If I want to change those, add new modules or upgrade some then I have to do the ./configure (with scads of options); make; make test; make install dance. At least with perl if I want to upgrade or add DBD::Pg it is separate from the perl core so I'm not forced to do the equivalent of recompiling perl and mod_perl.

    You are very confused. PHP offers native support for such things as imap and mysql. This is considered a *good* thing, but you have the choice of compiling php with or without such support. You don't compile PHP with "modules". PHP offers PEAR, which is similar in some respects to CPAN. You should read the FAQs on php.net.

      PHP offers native support for such things as imap and mysql. This is considered a *good* thing, but you have the choice of compiling php with or without such support. You don't compile PHP with "modules". PHP offers PEAR, which is similar in some respects to CPAN. You should read the FAQs on php.net.
      Yes, and that's what I'm wondering about. So if I compile PHP with a particular version of gd built in or don't include it at all, how do you upgrade that later? My inexperienced interpretation is that I'd have to recompile PHP to upgrade or add gd.

      Added Oh yeah, and it's that going-back and recompiling PHP that I categorized as 'torture'.


      Seeking Green geeks in Minnesota

        If you want native support and you installed PHP as a DSO, you would just type "make clean" (to get rid of previous configuration settings and makefiles), add the new configuration option to your configuration command, then type "make" and "make install" to build a new module. This new PHP module will be dumped in the proper location for Apache, and all you have to do is restart Apache for the proper module to be loaded, not recompile it. What is so difficult about this?

        PEAR is PHP's answer to CPAN. It is in its infancy, but it already offers many useful PHP classes. Many popular Perl modules have been (and are being) ported. You wouldn't have to recompile PHP to use one of the PEAR packages.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://232876]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others avoiding work at the Monastery: (3)
As of 2024-03-19 11:14 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found