Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
Message from discussion Solved: Apache 2.0.43 and php 4.3.0-dev on Linux
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
daneanderson  
View profile  
 More options Oct 18 2002, 7:32 pm
Newsgroups: comp.lang.php
From: d...@drydog.com (daneanderson)
Date: 18 Oct 2002 16:32:19 -0700
Local: Fri, Oct 18 2002 7:32 pm
Subject: Solved: Apache 2.0.43 and php 4.3.0-dev on Linux
For the archives, here's how I got Apache 2 and PHP working together on Linux
(RedHat 7.3). For future Apache versions, make sure you choose a version of
Apache released BEFORE the php release.  Using an Apache 2 released after a
PHP will probably not work.

I was only able to get PHP working with Apache 2 as a DSO.
I think that's the only way that's supported now.

I used httpd-2.0.43 and php-4.3.0-dev (php4-200210181200)
(from http://snaps.php.net/php4-latest.tar.gz )
php-4.3.0pre1 mostly worked, but my messages with Phorum (PHP app) were garbled
(probably a php/mysql bug).
I'm sure that fix will appear in the next prerelease of php-4.3.0 (pre2?).

0. Download/unpack Apache2 source.

1. In the Apache 2 source directory, type:
./configure --prefix=/usr/local/apache \
        --enable-so     \
        --enable-cgi    \
        --enable-info   \
        --enable-rewrite        \
        --enable-speling        \
        --enable-usertrack      \
        --enable-deflate \
        --enable-ssl    \
        --enable-mime-magic
make

2. If successful, install, as root:
        make install
3. In the php source directory, type:
./configure \
        --with-apxs2=/usr/local/apache/bin/apxs \
        --with-mysql \
        --prefix=/usr/local/apache/php \
        --with-config-file-path=/usr/local/apache/php \
        --enable-track-vars \
        --enable-force-cgi-redirect \
        --with-gettext \
        --with-gdbm
make

5. If successful, type, as root: make install-su
4. cp -p php.ini-recommended /usr/local/apache/php/php.ini
5. Make sure libs/libphp4.so is in /usr/local/apache/modules/
If not, copy it there)
6. Verify (and add if missing) these directives in
 /usr/local/apache/conf/httpd.conf:

        # Make sure there's only **1** line with this directive:
        LoadModule php4_module        modules/libphp4.so

        # Add index.php to your DirectoryIndex line:
        DirectoryIndex index.html index.php

        AddType application/x-httpd-php php

7. Start httpd:
        /usr/local/apache/bin/apachectl start
8. Sanity checks:
        ps -ef |grep httpd
        tail /usr/local/apache/logs/error_log
        /usr/local/apache/bin/httpd -v
        /usr/local/apache/bin/httpd -V
        /usr/local/apache/bin/httpd -l
        /usr/local/apache/bin/httpd -t
9. Access your webserver with your favorite browser.


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.