I'm following the beginner tutorial "Creating a Database Driven Application With PHP" in net beans.
I created the wishlist.php file that is referenced in the index.php file. When I run the index.php file:
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title></title>
</head>
<body>
<form action="wishlist.php" method="GET" name="wishList">
Show wish list of: <input type="text" name="user" value=""/>
<input type="submit" value="Go" />
</form>
</body>
</html>
the form comes up. I enter 'tom' and select the 'go' button.
According to the tutorial an empty page with the following URL should appear:
http://localhost:90/Lesson2/wishlist.php?user=tom
I get a webpage with the message:
This webpage is not found
and upon selecting 'more':
No webpage was found for the web address:
file:///C:/Users/Peter/AppData/Local/Temp/wishlist.php?user=tom Error
code: ERR_FILE_NOT_FOUND"
I don't know where the path "C:/Users/Peter/AppData/Local/Temp/" came from.
Basically there is nothing wrong the posted part of your script. As you can see your form redirects to the page it should redirect to. PHP is not even executed so we are assuming this will work when it is triggered correctly ;-)
But as I can see in your error description you are running the script locally in your home folder of your PC. Is there an webserver running? For executing PHP scripts you basically need to run a PHP service - usually a webserver like apache2.
If you don't have one try XAMPP which will install an apache webserver on your local PC.