I installed apache, it works fine. i extracted the PHP zip file to c:\php . thats all i did. what do i do now to get PHP to get working with Apache?
Printable View
I installed apache, it works fine. i extracted the PHP zip file to c:\php . thats all i did. what do i do now to get PHP to get working with Apache?
Add this to the config file
;)Code:AddType application/x-httpd-php .php
ScriptAlias /php/ "c:/path/to/php"
AddType application/x-httpd-php .php
Action application/x-httpd-php "/php/php.exe"
where at? just paste it in below the last line?
when i try to run a test.php file, i get a 404, but i know that the file is in the right spot. :confused:
oh boy.. you stepped in it this time... lol :D
you will have to get apache .conf file to notice php. did you put the php.ini and the dll in the right spot?
then you will have to go in and work on the httpd.conf
add index.php to this line
<IfModule mod_dir.c>
DirectoryIndex index.php index.htm index.html index.shtml
</IfModule>
then add it to this
ScriptAlias /cgi-bin/ "C:/Program Files/Apache Group/Apache/htdocs/yourFolder/cgi-bin/"
ScriptAlias /php4/ "C:/php/"
ScriptAlias /php3/ "C:/php/"
you don' thave to have php in the cgi-bin, as that works for me. don't ask why there is a cgi-bin there, I don't even use it. lol
and
# For example, the PHP 3.x module (not part of the Apache distribution - see
# http://www.php.net) will typically use:
#
AddType application/x-httpd-php3 .php3
AddType application/x-httpd-php3-source .php3s
#
# And for PHP 4.x, use:
#
AddType application/x-httpd-php .php
AddType application/x-httpd-php-source .phps
AddType application/x-httpd-php .php4
AddType application/x-httpd-php4 .php
AddType application/x-httpd-php4 .phtml
AddType application/x-tar .tgz
and here too, you may just ahve to uncomment out these lines and the ones above. not sure.
# Format: Action media/type /cgi-script/location
# Format: Action handler-name /cgi-script/location
#
Action application/x-httpd-php4 "/php/php.exe"
Action application/x-httpd-php4 "/php4/php.exe"
Action application/x-httpd-php4 "/php3/php.exe"
if you don't know where to placew those lines. just do a search for them and it should show up. it just maybe commented out so it will be there.
thanks a lot scoutt! :D:D:D:D:D