<?php echo " <form action='page.php' method='post'> <input type='text' name='a1'> <input type='text' name='a2'> <input type='submit' value='send'> </form> "; $a1 = $_POST['a1']; $a2 = $_POST['a2']; ?>