Name
<form> — NN 2, 3, 4, 6 MSIE 2,3, 4, 5.5, 6 HTML 4.01 WebTV Opera5
Synopsis
<form> ... </form>
Indicates the beginning and end of a form. There can be more than one form in an HTML document, but forms cannot be nested inside one another, and it is important that they do not overlap.
Attributes
-
accept=content-type-list Specifies a comma-separated list of file types (MIME types) that the server will accept and is able to process. Browsers may one day be able to filter out unacceptable files when prompting a user to upload files to the server, but this attribute is not yet widely supported.
-
accept-charset=charset list Specifies the list of character encodings for input data that must be accepted by the server in order to process the current form. The value is a space- and/or comma-delimited list of ISO character set names. The default value is
unknown. This attribute is not widely supported.
-
action=url Required. Specifies the URL of the application that will process the form. The default is the current URL.
-
enctype=encoding Specifies how the values for the form controls are encoded when they are submitted to the server when the method is
post. The default is the Internet Media Type (application/x-www-form-urlencoded). The valuemultipart/form-datashould be used in combination with thefileinput element.
-
method=get|post Specifies which HTTP method will be used to submit the form data. With
get(the default), the information is appended to and sent along with the URL ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access