[NTLUG:Discuss] Setting up virtual website on RH 8.0

Rob Apodaca rapodaca at raacc.com
Sat Jan 31 19:05:11 CST 2004


> When I tried browsing the PHP pages of the catalog
> software on my PC, the PHP was not processed.  I saw
> all the source, untranslated, on the screen.

In httpd.conf (or whatever your conf file is named) make sure this line
exists:
LoadModule php4_module modules/libphp4.so

Note: make sure 'modules/libphp4.so' is appropriate for your system.

You'll also need to tell apache which extensions should be parsed by
php:
AddType application/x-httpd-php .php .phtml

Make sure to restart apache for changes to take effect.

> 
> PHP 4.2.2 is active on my PC, as is Apache webserver.
> Even though there is a php.conf file in the
> /etc/httpd/conf.d directory, I tried adding the
> LoadModule lines to httpd.conf as recommended at
> http://us2.php.net/manual/en/faq.installation.php#faq.installation.processing
> I was not sure whether or where the AddModule lines
> should go in the httpd.comf file, but I tried putting
> them after the LoadModule lines.
> 
> Now if I try to browse localhost, Apache can not find
> the default html homepage anymore.  This does not
> sound like progress.

Look for an entry like this:
<IfModule mod_dir.c>
    DirectoryIndex index.html index.html.var index.php index.php3
index.shtml index.cgi index.pl index.htm Default.htm default.htm
</IfModule>

This tells apache which files are directory index files.

Good Luck.
-Rob




More information about the Discuss mailing list