Mega Code Archive

 
Categories / JavaScript Tutorial / Form
 

Form Basics

An HTML form is defined by using the element, which has several attributes: method -- Indicates whether the browser should sent a GET request or a POST request action -- Indicates the URL to which the form should be submitted enctype -- The way the data should be encoded when sent to the server. The default is application/x-www-url-encoded, but it may be set to multipart/form-data if the form is uploading a file. accept -- Lists the mime types the server will handle correctly when a file is uploaded accept-charset -- Lists the character encodings that are accepted by the server when data is submitted