Page 1 of 1

Apache is not processing the PHP file

Posted: Fri May 23, 2008 10:38 am
by mr palford
I know this question has been asked numerous times but even after spending an afternoon following several different sets of directions and debugging advice I'm still stuck.

I installed Apache 2.2.8 and PHP 5.2.6 on my dell Latitude lap top.

I created a simple php test file called info.php and placed it in the Apache htdocs directory.
<?
phpinfo();
?>
I request the page with http://localhost/info.php
Apache returns a blank screen. If I view the source with the browser I see the php code. Apache does not know what to do with a php file and is delivering the file as the response rather than processing it.

What I've tried:
First of all, the PHP install added the following to httpd.conf
PHPIniDir "C:/Program Files/PHP/"
LoadModule php5_module "C:/Program Files/PHP/php5apache2_2.dll"

I added:
AddType application/x-httpd-php .php .php5

What is missing?

Thanks for any help or guidance,
beeky

Re: Apache is not processing the PHP file

Posted: Fri May 23, 2008 2:19 pm
by VladSun
Did you restart the apache service after you edited its config files?

Re: Apache is not processing the PHP file

Posted: Tue May 27, 2008 9:06 am
by mr palford
I figured out what was wrong by looking through the archives of this forum. The problem was my usage of the 'old' php style <?...?> insead of <?php...?> in my php test program.

Thanks to all who responded,
-=beeky