<form action="myaction.php" method="post"> <p>Your name : <input type="text" name="name" /></p> <input type="submit" value="Submit"> </form> // myaction.php Hello <?php echo htmlspecialchars($_POST['name']); ?>