-
December 9th, 2007, 07:32 AM
#1
A Question about PHP
I created a test.php file in my inetpub folder and wrote the following script in that file, but when I access that page by url "http://localhost/test.php" it prompts me the error "The page cannot be found ", can anyone please guide what am I doing wrong.
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<head>
<title>My First PHP Page</title>
</head>
<body>
<h1>My First PHP Page</h1>
<?php
echo '<p>This is my first PHP script.</p>';
?>
</body>
</html>
Thanks and Best Regards,
Mushq
-
December 9th, 2007, 08:56 AM
#2
Re: A Question about PHP
Simple answer is that you have something configured wrong. I am assuming you are using IIS since you mentioned the inetpub folder. Another assumption would be that no HTML or PHP file can be found in your localhost. Am I correct?
If the post was helpful...Rate it! Remember to use [code] or [php] tags.
-
December 11th, 2007, 09:29 AM
#3
Re: A Question about PHP
As PeejAvery already mentioned it looks like a configuration problem.
Give us some more information about your installation (iis version, php version aso.) and configuration.
And check-out this
http://wiki.phpgedview.net/en/index...._PHP_and_MySQL
http://hostlibrary.com/ConfiguringPH...erver2003.html
-
December 11th, 2007, 03:22 PM
#4
Re: A Question about PHP
Originally Posted by Mushq
I created a test.php file in my inetpub folder and wrote the following script in that file, but when I access that page by url "http://localhost/test.php" it prompts me the error "The page cannot be found ", can anyone please guide what am I doing wrong.
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<head>
<title>My First PHP Page</title>
</head>
<body>
<h1>My First PHP Page</h1>
<?php
echo '<p>This is my first PHP script.</p>';
?>
</body>
</html>
Thanks and Best Regards,
Mushq
make sure your page is in "\Inetpub\wwwroot" folder and not in "Inetpub" folder
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|