Forum Moderators: coopster

Message Too Old, No Replies

PHP Apache communication

The requested URL /phpinfo.php was not found on this server.

         

AranhaHunter

9:51 pm on Sep 25, 2005 (gmt 0)

10+ Year Member



I have to install Apache and PHP on my computer after formatting it, but I'm having problems. I know apache and php are communicating because if I make changes to php.ini and restart the apache server, it complains, however when I put phpinfo.php on my folder c:\sites\creativecabana (I have also saved it on c:\apache2\apache2\htdocs to test) and they show me a 404 not found, The requested URL /phpinfo.php was not found on this server.
Please help

I can't post the whole file because it's not accepting it for some reason

this is the part that I changed on php.ini

[CODE]
;;;;;;;;;;;;;;;;;;;;;;;;;
; Paths and Directories ;
;;;;;;;;;;;;;;;;;;;;;;;;;

; UNIX: "/path1:/path2"
;include_path = ".:/php/includes"
;
; Windows: "\path1;\path2"
;include_path = ".;c:\php\includes"

; The root of the PHP pages, used only if nonempty.
; if PHP was not compiled with FORCE_REDIRECT, you SHOULD set doc_root
; if you are running php as a CGI under any web server (other than IIS)
; see documentation for security issues. The alternate is to use the
; cgi.force_redirect configuration below
doc_root= "C:/Apache2/Apache2/htdocs"
[\CODE]

[edited by: AranhaHunter at 10:00 pm (utc) on Sep. 25, 2005]

AranhaHunter

9:56 pm on Sep 25, 2005 (gmt 0)

10+ Year Member



this is the part I changed on http.conf

#ExtendedStatus On
LoadModule php5_module "c:/Apache2/php5/php5apache2.dll"
AddType application/x-httpd-php .php
# configure the path to php.ini
PHPIniDir "C:/Apache2/php5"
AddHandler server-parsed .shtml

#
# DocumentRoot: The directory out of which you will serve your
# documents. By default, all requests are taken from this directory, but
# symbolic links and aliases may be used to point to other locations.
#
DocumentRoot "C:/Apache2/Apache2/htdocs"

#
# Each directory to which Apache has access can be configured with respect
# to which services and features are allowed and/or disabled in that
# directory (and its subdirectories).
#
# First, we configure the "default" to be a very restrictive set of
# features.
#
<Directory />
Options FollowSymLinks
AllowOverride None
</Directory>

<Directory "c:/sites/creativecabana/*/">
AllowOverride None
AddHandler server-parsed .shtml
Options FollowSymLinks +Includes
Order allow,deny
Allow from all
AddOutputFilter INCLUDES;DEFLATE shtml
</Directory>

#
# Note that from this point forward you must specifically allow
# particular features to be enabled - so if something's not working as
# you might expect, make sure that you have specifically enabled it
# below.
#

#
# This should be changed to whatever you set DocumentRoot to.
#
<Directory "C:/Apache2/Apache2/htdocs">

NameVirtualHost *

<VirtualHost *>
ServerName creativecabana.com
# Line Below - If you have a DynDNS account , Discussed later article.
ServerAlias www.creativecabana.dnsalias.com
ServerAdmin webmaster@creativecabana
DocumentRoot "c:/sites/creativecabana"
ErrorLog "logs/creativecabana.com-error_log"
# Line below - 'combined' gives us good detailed stats (Later Article)
CustomLog logs/creativecabana.com-access_log combined
UseCanonicalName off
AddHandler server-parsed .shtml Options FollowSymLinks +Includes
AddType text/html .shtml
AddOutputFilter INCLUDES .shtml
<IfModule mod_ssl.c>
Include conf/ssl.conf
</IfModule>
</VirtualHost>

AranhaHunter

1:20 pm on Sep 26, 2005 (gmt 0)

10+ Year Member



Nobody? I changed the
NameVirtualHost * to NameVirtualHost *:80 and nothing happened. I also get apache's page when I go to localhost, but a forbidden message when I go to 127.0.0.1. Finnally, Apache keeps complaining when I uncomment extension=php_mysql.dll, even when I change the extension dir to
extension_dir = "c:\apache2\apache2\php5\ext\"
It says PHP Startup: Unable to load dynamic library 'c:\apache2\apache2\php5\ext\php_mysql.dll' - The specified module could not be found.

coopster

7:42 pm on Sep 26, 2005 (gmt 0)

WebmasterWorld Administrator 10+ Year Member



Welcome to WebmasterWorld, AranhaHunter.

There is a thread in the PHP Forum Library [webmasterworld.com] that might help.

Installing PHP5 Under Windows XP and Apache [webmasterworld.com]

There is also a thread in the PHP Forum Library that describes some troubleshooting steps for PHP/Apache on Windows.