note 86146 added to tutorial.forms

From: Date: Sun, 05 Oct 2008 19:03:42 +0000
Subject: note 86146 added to tutorial.forms
Groups: php.notes 
Request: Send a blank email to php-notes+get-145075@lists.php.net to get a copy of this message
Good tips everybody, thanks! A brief summary: SERVER-SIDE PROCESSING (GET and POST) <!-- If your form submission WILL NOT WRITE anything on the SERVER-SIDE, use GET --> <form action="action.php" method="get"> <!-- If your form submission WILL WRITE some data on the SERVER-SIDE, use POST --> <form action="action.php" method="post"> CLIENT-SIDE PROCESSING (ID and NAME) <!-- If the CLIENT-SIDE NEEDS to access or modify this field, use the id attribute --> <input id="firstName" name="firstName" type="text"> <!-- create a script that runs on the CLIENT-SIDE to access and modify the field --> <script type="javascript"> var firstName = document.getElementById("firstName"); firstName.value = 'some text'; firstName.focus(); </script> <!-- If the CLIENT-SIDE DOES NOT NEED to access or modify this field, --> <!-- then there is no need for the ID attribute or a client side script --> <input name="firstName" type="text"> Note the HTML SYNTAX: - In <form>, 'get' and 'post' are the VALUE of the attribute named 'method'. - In <input>, 'id' and 'name' are the NAME of the attribute with values of 'firstName'. ---- Server IP: 69.147.83.197 Probable Submitter: 67.150.124.194 ---- Manual Page -- http://www.php.net/manual/en/tutorial.forms.php Edit -- https://master.php.net/note/edit/86146 Del: integrated -- https://master.php.net/note/delete/86146/integrated Del: useless -- https://master.php.net/note/delete/86146/useless Del: bad code -- https://master.php.net/note/delete/86146/bad+code Del: spam -- https://master.php.net/note/delete/86146/spam Del: non-english -- https://master.php.net/note/delete/86146/non-english Del: in docs -- https://master.php.net/note/delete/86146/in+docs Del: other reasons-- https://master.php.net/note/delete/86146 Reject -- https://master.php.net/note/reject/86146 Search -- https://master.php.net/manage/user-notes.php

« previous php.notes (#145075) next »