Over a million developers have joined DZone.

HTML Forms

DZone's Guide to

HTML Forms

· ·
Free Resource
FORM - With the help of the following elements you can create questionnaires and different fields for text inputting with the possibility of subsequent sending the submitted forms to your server. 

Elements for form creating: 

FORM - creates a form 

TEXTAREA - creates a field for inputting a few lines of text 

SELECT - creates a menu 

OPTION - Creates a separate items of the menu (see SELECT) 

INPUT - creates a field in the form 

FORM - is used to create a form. It should be the presence of initial and ending tags. Inside the FORM element the use of the majority of HTML-elements is allowed. ( PHP form as an example)
NAME - defines the name of the form, unique to this document. Used if there is a few forms in the document. 

ACTION - a required attribute. Specifies the URL for sending the form content - the path to the script of the server that acts in current form. 

METHOD - defines the way to send the contents of the form. Possible values are GET (default) and POST. 

ENCTYPE - defines the method of coding the contents of the form when you send. The default is "application / x-www-form-urlencoded". 

TARGET - defines the name of the window, which returns a result of a submitted form. Possible values: _self, _parent, _top, _blank, or clearly specified the name of the window. Look all4soft.com


     <- Creating a form ->
Last Name:

Opinions expressed by DZone contributors are their own.

{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}