Categories:
.NET (357)
C (330)
C++ (183)
CSS (84)
DBA (2)
General (7)
HTML (4)
Java (574)
JavaScript (106)
JSP (66)
Oracle (114)
Perl (46)
Perl (1)
PHP (1)
PL/SQL (1)
RSS (51)
Software QA (13)
SQL Server (1)
Windows (1)
XHTML (173)
Other Resources:
What Are the Attributes of a FORM Element
What Are the Attributes of a FORM Element? - XHTML 1.0 Tutorials - Understanding Forms and Input Fields
✍: FYIcenter.com
There are 3 commonly used attributes for a "form" element:
The URL of the form processing program is usually given to you by the Webmaster. You just put it into the "action" attribute directly. If you specify an empty "action" attribute, the URL of the current XHTML document will be used to submit the form data.
From an XHTML document author's point of view, method="get" and method="post" have no differences. Both of them will submit viewers input data to the submission program specified in the "action' attribute.
The default setting for enctype="application/x-www-form-urlencoded" for most of your forms. But you want upload files through a form, you need to use enctype="multipart/form-data" and method="post".
Some examples of "form" element with different attributes:
<!-- Submitting to the URL of the current document --> <form action=""></form> <!-- Submitting to a perl program --> <form action="/cgi-bin/survey.pl"></form> <!-- Submitting to a PHP program --> <form action="/survey.php" method="post"></form> <!-- Submitting to a PHP program for file uploading --> <form action="/upload.php" method="post" enctype="multipart/form-data"></form>
2007-05-12, 4635👍, 0💬
Popular Posts:
Would I use print "$a dollars" or "{$a} dollars" to print out the amount of dollars in this example?...
What will be printed as the result of the operation below: #define swap(a,b) a=a+b;b=a-b;a=a-b; void...
How To Display a Past Time in Days, Hours and Minutes? - MySQL FAQs - Managing Tables and Running Qu...
What’s the difference between Unit testing, Assembly testing and Regression testing? Unit testing is...
Can we use the constructor, instead of init(), to initialize servlet? Yes , of course you can use th...