Created
December 16, 2012 22:35
-
-
Save MarkyC/4313770 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <html> | |
| <body> | |
| <form <!-- This specifies a form HTML element: https://developer.mozilla.org/en-US/docs/HTML/Element/form --> | |
| action="formProcessor.php" <!-- path to a script that processes the form --> | |
| method="post"> <!-- general rule: POST sends data, GET gets data. Forms send data --> | |
| <label> <!-- A label element /labels/ the input element --> | |
| Enter Your Text Here: | |
| <input <!-- input HTML element: https://developer.mozilla.org/en-US/docs/HTML/Element/input --> | |
| name="myInput" <!-- The name of the input, used by formProcessor.php to retrieve the text from the input --> | |
| type="text"> <!-- An input of type text is a single line textfield --> | |
| </label> | |
| <input type="submit"> <!-- We need a submit button to submit the form! --> | |
| </form> | |
| </body> | |
| </html> | |
| ## formProcessor.php [php] | |
| <html> | |
| <body> | |
| <h1> | |
| You entered: <?php echo $_POST['myInput'] ?> | |
| </h1> | |
| </body> | |
| </html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment