Newbie problem: Php script not running in browser.
| From: | V S Rawat | Date: | Tue, 05 Aug 2008 19:05:10 +0000 |
| Subject: | Newbie problem: Php script not running in browser. | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-277749@lists.php.net to get a copy of this message | ||
I have put the first php script to hello.php file:
<html>
<head>
<title>PHP Test</title>
</head>
<body>
<?php echo '<p>Hello World</p>'; ?>
</body>
</html>
I am on xpsp3, wampserver 2.0, having apache 2.2.8, php 5.2.6, MySQL 5.0.51b
http://localhost/ is E:\wamp\www
I put the hello.php file to E:\wamp\www. drag/dropping it to browser
shows the above source code in ff3/ie6
putting it to E:\wamp\bin\apache\apache2.2.8\htdocs and drag/dropping it
to browser shows the same source code.
However, putting it to E:\wamp\www\php_ex but giving
http://localhost/hello.php shows a blank screen
I have forgotten some situation where it had appeared as
Hello World
'; ?>
on the browser.
E:\wamp\bin\apache\apache2.2.8\conf\httpd.conf file has the lines:
LoadModule php5_module "e:/wamp/bin/php/php5.2.6/php5apache2_2.dll"
AddType application/x-httpd-php .php
AddType application/x-httpd-php .php3
On double clicking the php file in windows explorer, it opens in notepad
for edit, instead of getting opened in firefox that is my default.
Please give me the starting push.
-- V