Link to home
Start Free TrialLog in
Avatar of Vladimir Buzalka
Vladimir BuzalkaFlag for Czechia

asked on

PHP4 and Apache2 and Windows XP - no success yet

Hi all,

I installed PHP4 and Apache 2 on my Windows XP machine, I created phptest.php file which contains
<? phpinfo(); ?>

But when I click on that WExplorer just wants to either open it or save it.

Obviously it does not process the file as PHP file.

Can you plz help?

Thanks

Vladimir
Avatar of minichicken
minichicken

Hi

in your httpd.conf, you need to set your documentRoot directory, this is where all your PHP files should sit under.
Example:
DocumentRoot "C:/Program Files/Apache/Apache2/htdocs"

and also setup your # To use server-parsed PHP files
Example:
AddType application/x-httpd-php .php .php3 .php4 .phtml
If you are using php as a module rather than cgi you also need to add a line like this one:

LoadModule php4_module "c:/path/to/php/sapi/php4apache2.dll"

You can put it with the other LoadModule lines.
If you used the executable installer from php.net (instead of the zip version) then you are using CGI and can disregard my post :)
ASKER CERTIFIED SOLUTION
Avatar of ronan_40060
ronan_40060
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
check out another good resources for PHP
http://www.sitepoint.com/subcat/php-tutorials