Page 1 of 1

PHP And Programming Newbie

Posted: Thu Oct 16, 2008 11:45 pm
by buck2576
I have taken up programming in an attempt to broaden my employment capabilities in such a crappy economy (and also since it's what everyone thought I was going to do anyways).
Having said that, I know this question has been posted a million times, but I just can't find the help I need so . . . :

I need Apache and PHP to get along. When I try to run the info test with .php I get a 404 error, but when I run it as .html it comes up with the following information:

Configuration File (php.ini) Path . . . C:\Windows

I guess the path should probably be C:\php\. How do I make these changes? I have tried placing the php.ini file in C:\Windows with no luck. How do I change the path to C:\php\? And PLEASE don't send me a link to php.net/manual. I am getting NOTHING from their configuration settings. Remember, I'm a NEWBIE! Thanks pals.

Buck

bbuckholtz at gmail dot com

Re: PHP And Programming Newbie

Posted: Fri Oct 17, 2008 4:59 am
by VladSun
In Apache httpd.cong you should have these or similar lines:

Code: Select all

LoadModule php5_module "C:/php/php5apache2_2.dll"
PHPIniDir "C:/php"
......
<IfModule dir_module>
    DirectoryIndex index.php index.php5 index.php4 index.htm index.html
</IfModule>
......
 
<IfModule mime_module>
......
    AddType application/x-httpd-php .php    
    AddType application/x-httpd-php .php5    
......