Hey 70363137
You need to correct your $usertext - or at least when it is set.
You can do it like this: -
<html>
<head>
<title>A FORM</title>
<?php
if (isset($_POST['Submit']))
{
$usertext = $_POST['example'];
}
else
{
$usertext="Enter Text Here";
}
?>
</head>
<body>
<form name="form1" method="post" action="">
<input type='text' name='example' value="<?php print $usertext; ?>"
<input type = "Submit" name = "Submit" value = "Submit">
<br/>
</form>
</body>
</html>
If you click on "Submit", the variable is set to whatever was entered and gets re-displayed in the text box, if the form was NOT submitted then the default text gets assigned to the variable and entered in the text box.
Glen