below i have code from a simple php form program. you are supposed to enter your name in a text box and push the submit button. it then is supposed to bring you to a page that says "hello --your name here-- "
but instead it says "Hello $userName!; ?>" i tried rewriting it, ive tried fixing it different ways, and i thought maybe it had something to do with "register_globa ls" but i have a severe lack of understanding of it. however i do have it turned on (as i remember). anyways, here is the code of the original page first and after i will have the code of the second page. thanks
now here is the second page
but instead it says "Hello $userName!; ?>" i tried rewriting it, ive tried fixing it different ways, and i thought maybe it had something to do with "register_globa ls" but i have a severe lack of understanding of it. however i do have it turned on (as i remember). anyways, here is the code of the original page first and after i will have the code of the second page. thanks
Code:
<html> <head> <title> psuedo login </title> </head> <body> <h1> What is your name?</h1> <h3> form for user input</h3> <form method = "post" action = "hiUser.php"> Please type name here: <input type = "text" name = "userName" value = ""> <br> <input type = "submit"> </form> </body> </html>
Code:
<html> <head> <title> then you must be...</title> </head> <body> <h1>Hi User</h1> <h3> php program that recieves a value from "index.html"</h3> <? print <h3> Hello $userName!</h3>; ?> </body> </html>
Comment