php file not run
i want to run phpinfo.php file
<html> <body> <?php phpinfo(); ?> </body> </html> and save this file to location "/var/www/html" and i also edit the httpd.conf file and add the module LoadModule php5_module modules/libphp5.so AddType application/x-httpd-php-source .phps AddType application/x-httpd-php .php AddType text/html .php and when type http://localhost/phpinfo.php ,i shows nothing on the browser and i got following log 127.0.0.1 - - [19/Aug/2009:16:55:00 +0530] "GET /phpinfo.php HTTP/1.1" 200 - "-" "Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1.2) Gecko/20090729 Firefox/3.5.2" 127.0.0.1 - - [19/Aug/2009:16:55:00 +0530] "GET /phpinfo.php HTTP/1.1" 200 - "-" "Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1.2) Gecko/20090729 Firefox/3.5.2" thanks |
Are your sure apache is running? What happens if you open http://localhost ?
|
yes it is running
|
|
What is the output of:
Code:
php -v Code:
<html> |
Quote:
Paste your virtual host entry from httpd.conf please. |
yes index.html file load
virtual host entry in httpd.conf file ### Section 3: Virtual Hosts # # VirtualHost: If you want to maintain multiple domains/hostnames on your # machine you can setup VirtualHost containers for them. Most configurations # use only name-based virtual hosts so the server doesn't need to worry about # IP addresses. This is indicated by the asterisks in the directives below. # # Please see the documentation at # <URL:http://httpd.apache.org/docs/2.2/vhosts/> # for further details before you try to setup virtual hosts. # # You may use the command line option '-S' to verify your virtual host # configuration. # # Use name-based virtual hosting. # #NameVirtualHost *:80 # # NOTE: NameVirtualHost cannot be used without a port specifier # (e.g. :80) if mod_ssl is being used, due to the nature of the # SSL protocol. # # # VirtualHost example: # Almost any Apache directive may go into a VirtualHost container. # The first VirtualHost section is used for requests without a known # server name. # #<VirtualHost *:80> # ServerAdmin webmaster@dummy-host.example.com # DocumentRoot /www/docs/dummy-host.example.com # ServerName dummy-host.example.com # ErrorLog logs/dummy-host.example.com-error_log # CustomLog logs/dummy-host.example.com-access_log common #</VirtualHost> |
All times are GMT -5. The time now is 05:48 PM. |