Board index   FAQ   Search  
Register  Login
Board index PHP PHP Installation

PHP 5.2.17 Apache 2.2 Win7

Forum for you who has PHP installation issues

Moderators: macek, egami, gesf

PHP 5.2.17 Apache 2.2 Win7

Postby RonInNewYork » Tue Apr 12, 2011 9:09 am

I successfully installed PHP and Apache on my XP machine, but not on Win7. When I try to run the PHP installer I get an error that it cannot access httpd.conf.

Now, Apache 2.2 does work (I get IT WORKS) when I go to 127.0.0.1. I manually edited httpd.conf to include

#BEGIN PHP INSTALLER EDITS - REMOVE ONLY ON UNINSTALL
PHPIniDir "C:\Program Files\PHP"
LoadModule php5_module "php5apache2_2.dll"
#END PHP INSTALLER EDITS - REMOVE ONLY ON UNINSTALL

If I don't have the dll in the Apache 2.2 main folder I get an error.

What to do?
Thanks.

RON
RonInNewYork
New php-forum User
New php-forum User
 
Posts: 9
Joined: Fri Apr 08, 2011 1:36 pm

Re: PHP 5.2.17 Apache 2.2 Win7

Postby egami » Tue Apr 12, 2011 9:35 am

I'm no Windows expert, but it sounds like a $PATH issue.
User avatar
egami
php-forum GURU
php-forum GURU
 
Posts: 2197
Joined: Wed Oct 06, 2010 11:19 am
Location: Happy Valley, UT

Re: PHP 5.2.17 Apache 2.2 Win7

Postby RonInNewYork » Tue Apr 12, 2011 9:39 am

The PHP Path is there; also php -r "phpinfo();" works just fine. But when I try to access PHP files in the htdocs folder I get just the text of the file.
RonInNewYork
New php-forum User
New php-forum User
 
Posts: 9
Joined: Fri Apr 08, 2011 1:36 pm

Re: PHP 5.2.17 Apache 2.2 Win7

Postby egami » Tue Apr 12, 2011 9:43 am

ok, did you add these lines to http.conf ?

LoadModule php5_module modules/libphp5.so
# <<< I am assuming windows would be c:\progra~1\php\modules\libphp5.dll or something idiotic like..
# << or so as such c://program files//php//modules//libphp5.dll
# << You'll have to play with it to find out, or RTM.

AddHandler php5-script .php
AddType text/html .php

DirectoryIndex index.php, index.html

AddType application/x-httpd-php-source .phps
User avatar
egami
php-forum GURU
php-forum GURU
 
Posts: 2197
Joined: Wed Oct 06, 2010 11:19 am
Location: Happy Valley, UT

Postby RonInNewYork » Tue Apr 12, 2011 9:58 am

THAT'S IT!!! THANKS VERY MUCH.


RON
RonInNewYork
New php-forum User
New php-forum User
 
Posts: 9
Joined: Fri Apr 08, 2011 1:36 pm


Return to PHP Installation

Who is online

Users browsing this forum: Bing [Bot] and 1 guest

Sponsored by Sitebuilder Web hosting and Traduzioni Italiano Rumeno and antispam for cPanel.

cron