RE: php4-cli or mod_php4
Hi, > Correct solution would be to install mod_php4 first and then > install all the necessary extensions via separate ports. For instance, to > get MySQL support in PHP you would install /usr/ports/databases/php4-mysql. > > This way of installing extensions via ports was introduced when PHP > 4.3.8 came out (and was mentioned in /usr/ports/UPDATING). I C. I wonder why they did this... Oh well, never mind. It's good to know at least that there's no need to fully recompile everything the way I did it (live and learn). A quick question: did you happen to try this with GD2 as well? I want to install the latest version 2.0.28 (IIRC) and I haven't yet gotten around to doing so. I was wondering if GD2 can also be added flawlessly like this, or whether GD2 does require a recompilation. Anyway, if you don't know off-hand, it matters not. In that case I shall simply RTFM for the proper installation procedure... Cheers! Olafo ___ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "[EMAIL PROTECTED]"
Re: php4-cli or mod_php4
Olaf Greve wrote: It seems that as of fBSD 5.3, the version that is installed when using sysinstall has a lot less compile options enabled than it used to do previously, one of which being the MySQL support. Here's what I did to solve the issue: 1) Install Apache 1.3, PHP4 (MOD + CLI), PHP4 extensions. 2) Make sure this combination can successfully execute a simple 'hello world' example. 3) Figure out PHP's compilation options (this can be done e.g. using PHPinfo). ... etc. Well, that's certainly one way, but it's not The Way ;-) Correct solution would be to install mod_php4 first and then install all the necessary extensions via separate ports. For instance, to get MySQL support in PHP you would install /usr/ports/databases/php4-mysql. This way of installing extensions via ports was introduced when PHP 4.3.8 came out (and was mentioned in /usr/ports/UPDATING). ___ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "[EMAIL PROTECTED]"
RE: php4-cli or mod_php4
Hi, > > i want to install apache+php+mysql. If i install mod_php i cannot > >install php4-extension (mysql, etc ...). If i try to install php4-cli > >and extensions apache doesn't know how to handle .php files . What's the > >they to go to make apache work with mysql and php ? fBSD is 5.3. Well, up until fBSD 5.2.1 when installing PHP4 and Apache 1.3 using sysinstall, matters would all automatically be swell. Then, the other day I installed fBSD 5.3 on a client's machine, then I did the same trick by installing Apache 1.3, PHP4 + extensions and I tested the combination. A simple 'hello world' script worked a charm, but then I put the actual application on the machine, and all sorts of things would not work! It seems that as of fBSD 5.3, the version that is installed when using sysinstall has a lot less compile options enabled than it used to do previously, one of which being the MySQL support. Here's what I did to solve the issue: 1) Install Apache 1.3, PHP4 (MOD + CLI), PHP4 extensions. 2) Make sure this combination can successfully execute a simple 'hello world' example. 3) Figure out PHP's compilation options (this can be done e.g. using PHPinfo). 4) If possible, compare these options to those of a system on which everything works as it should (I was lucky enough to be able to do so, but perhaps you do not have access to such a system). No write down the compilation options that you're missing in your installation (e.g. something like --enable-mysql, etc.). 5) Go to the proper ports directory, which I think (if memory serves me right here) is something like /ports/lang/php4. Check the Makefile structure, in the beginning of that file you can see PHP's compilation options. 6) Add the missing options to this file. Perform a 'make remove' (to first uninstall PHP4), then perform a 'make all' followed by a 'make install' (I think these were the steps). 7) Restart apache using 'apachectl restart' and check the compilation options again. If you did this process correctly, PHP should work fine now. Note: enabling PHP4 from the Apache httpd.conf file is not that difficult. If your 'hello world' example fails to run, and you can't figure out which configuration options to set in Apache's httpd.conf file, and/or in PHP's php.ini file, please let me know. I've done this several times now, so I can probably help you out with it... Cheerz! Olafo ___ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "[EMAIL PROTECTED]"
Re: php4-cli or mod_php4
Cristi Tauber wrote: Hello list, i want to install apache+php+mysql. If i install mod_php i cannot install php4-extension (mysql, etc ...). If i try to install php4-cli and extensions apache doesn't know how to handle .php files . What's the they to go to make apache work with mysql and php ? fBSD is 5.3. Thanks, Cristi I would recommend installing /lang/php4 and /lang/php4-extensions. /lang/php4 is something of a "meta" port that builds the Apache module, the CLI, and I *think* the CGI (IIRC), if you should want that. The extensions will certainly build with it, and I've actually found that since I'm a little better in PHP than most shell languages, I can use the CLI for a variety of tasks without spending all my time reading about how to script bash There are a few things to check if your Apache installation *still* doesn't execute *.php scripts, but I feel confident that installating the two ports mentioned above will handle all, or almost all, or this for you. HTH, Kevin Kinsey ___ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "[EMAIL PROTECTED]"
RE: php4-cli or mod_php4
By installing php4-extensions it will auto to using mod_php with apache. I have never had a lick of trouble with apache 1.3 and the above mentioned set-up. Although, as the message states many have complained of trouble with 2. I recommend installing mysql 1st, apache 1.3 2nd, then the php4-extensions. Best, Thomas S. Crum -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Andrew L. Gould Sent: Friday, December 03, 2004 8:45 AM To: Cristi Tauber Cc: FreeBSD Question Subject: Re: php4-cli or mod_php4 On Fri, 03 Dec 2004 15:30:15 +0200 Cristi Tauber <[EMAIL PROTECTED]> wrote: >Hello list, > > i want to install apache+php+mysql. If i install mod_php i cannot > install php4-extension (mysql, etc ...). If i try to install php4-cli > and extensions apache doesn't know how to handle .php files . What's > the they to go to make apache work with mysql and php ? fBSD is 5.3. > > Thanks, > > Cristi Hi Cristi, Install php4-extensions; and then follow these instructions, which are found in /usr/ports/lang/php4/pkg-message.mod: *** Make sure index.php is part of your DirectoryIndex. You should add the following to your Apache configuration file: AddType application/x-httpd-php .php AddType application/x-httpd-php-source .phps *** You're next big question may be whether to use apache 1.3 or apache 2, as I keep seeing references on the internet about people having problems with php and apache 2. Best regards, Andrew Gould ___ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "[EMAIL PROTECTED]" ___ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "[EMAIL PROTECTED]"
Re: php4-cli or mod_php4
On Fri, 03 Dec 2004 15:30:15 +0200 Cristi Tauber <[EMAIL PROTECTED]> wrote: >Hello list, > > i want to install apache+php+mysql. If i install mod_php i cannot > install php4-extension (mysql, etc ...). If i try to install php4-cli > and extensions apache doesn't know how to handle .php files . What's > the they to go to make apache work with mysql and php ? fBSD is 5.3. > > Thanks, > > Cristi Hi Cristi, Install php4-extensions; and then follow these instructions, which are found in /usr/ports/lang/php4/pkg-message.mod: *** Make sure index.php is part of your DirectoryIndex. You should add the following to your Apache configuration file: AddType application/x-httpd-php .php AddType application/x-httpd-php-source .phps *** You're next big question may be whether to use apache 1.3 or apache 2, as I keep seeing references on the internet about people having problems with php and apache 2. Best regards, Andrew Gould ___ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "[EMAIL PROTECTED]"