Configuring Apache and PHP

Need help installing PHP, configuring a script, or configuring a server? Then come on in and post your questions! We'll try to help the best we can!

Moderator: General Moderators

Post Reply
pcb
Forum Newbie
Posts: 4
Joined: Thu May 10, 2007 6:38 am

Configuring Apache and PHP

Post by pcb »

I have a problem with configuring the apache and php, for your information, i download the php, mysql and apache in separate way. the problem i face is, before this, i'm using the foxserv where everythings in one suite. but when i run my project, the codes cannot function. i give somebody my source code and he try, suprisingly everythings ok, after he ask me to configure something with foxserv, still the codes cannot run. he tells me me that he using php, mysql and apache separately, maybe because of that. so i try to install in separate way, but now, i dont know how to tell the apache to handle the *.php file. and i ask somebody again and he say that change the line

DirectoryIndex index.html index.html.var
and add the
DirectoryIndex index.html index.html.var index.php

but still no works, when i test via my browser, http://localhost/M@S/index.php. the window that promt to download the index.php. i dont know why, please help me, i spent a whole night just to configure it...

thanks in advance
pcb
Forum Newbie
Posts: 4
Joined: Thu May 10, 2007 6:38 am

Post by pcb »

anyone can help me??
unorthodokz
Forum Newbie
Posts: 11
Joined: Tue Apr 10, 2007 2:33 pm
Location: Nashville, TN

Post by unorthodokz »

Try EasyPHP. http://www.easyphp.org/telechargements.php3

A lot of it is in french, but it's fairly easy to use and I didn't have too many issues with getting it all working straight.
phpW2L
Forum Newbie
Posts: 1
Joined: Wed May 16, 2007 3:37 pm

Apache Config for PHP

Post by phpW2L »

I'm very new to PHP, in fact, i'm still trying to set up apache to recognize and parse the files.

Books, and various websites tell me to open the apache "httpd.config" file and add the following code:

LoadModule php5_module C:/php5/php5apache2.dll <----- "C:/php5" is in fact the directory I installed PHP into
AddType application/x-htppd-php .php <----- I'm assuming this tells apache to send .php files to the above directory for parsing

Then I'm supposed to copy/paste the "php.ini-recommended" to my apache directory and rename it "php.ini"


However, it's at this point where apache does not restart like it should 8O . So I am at a loss as to where I'm going wrong and would love some assistance.

I'm using Apache2.2 with openSSL support on a WindowsXP and PHP version 5, if that is any help.


Until I figure out what's going wrong, I am prevented from even learning or testing the <? phpinfo(); ?> lol. Please help!


EDIT: It may be of use to know that if I take out those two lines from the httpd.config, Apache will start up as it should. Maybe it depends on where i put these lines?
User avatar
guitarlvr
Forum Contributor
Posts: 245
Joined: Wed Mar 21, 2007 10:35 pm

Post by guitarlvr »

check out this thread at apachelounge.com. very easy to follow directions and it hasn't failed me yet.

Wayne
Post Reply