Professional Documents
Culture Documents
INTRODUCTION
Form is used: Email subscriptions Contest registrations Databases Autoresponders User identifications and passwords Feedback
INTRODUCTION
Method - Determines which http method will be used to send the form's information to the web server. GET - This method will append all of the information from a form on to the end of the URL being requested. POST - This method will transmit all of the information from a form immediately after the requested URL. This is the preferred method. Action - The URL of the form processing script that resides on the server. This script will process the form's information.
Faculty Computer Science Engineering
FORM ELEMENTS
Button Text boxes Hidde Password Checkbox Radio button Submit Image submit Reset
Checkbox
Radio Textarea
Submit
Reset
Faculty Computer Science Engineering
SELECTION LIST
The <select> tag is used to create a select list (drop-down list). The <option> tags inside the select element define the available options in the list. <Select Name=Name Size=n Multiple> <Option Value=Value selected>Option 1 <Option Value=Value > Option 2 </Select>
SELECTION LIST
Select Attributes NAME - Name of the variable to be processed by the form processing script. SIZE - Specifies the number of visible selections. MULTIPLE - Enables users to select multiple selections. Option Attributes SELECTED - Specifies a default selection. VALUE - Specifies the value of the variable in the select element.
Faculty Computer Science Engineering
SELECTION LIST
Example: <body><form> <select Name=Product> <option value=1>ScanMaster <option value=3>ScanMaster II <option value=4>LaserPrint 1000 <option value=5> LaserPrint 5000 <option value=6>Print/scan 150 <option value=7> Print/scan 250 </Select> </form></body>
SELECTION LIST
<form> <select Name=Product size=5 Multiple> <option value=1>ScanMaster <option value=3>ScanMaster II <option value=4>LaserPrint 1000 <option value=5> LaserPrint 5000 <option value=6>Print/scan 150 <option value=7> Print/scan 250 </Select> </form>
Faculty Computer Science Engineering
SELECTION LIST
OPTGROUP: is used to group the elements in selection list <SELECT name= Text> <OPTGROUP> <OPTION value= value1>option1 <OPTION value= value2> option2 . </OPTGROUP> </SELECT>
Faculty Computer Science Engineering
SELECTION LIST
<SELECT name= course> <OPTGROUP> <OPTION value= Internetintro>Introduction to the Internet <OPTION value= Introhtml>Introduction to HTML <OPTION value= Introweb>Introduction to the web page designing </OPTGROUP> <OPTGROUP> <OPTION value= vbintro>Visual Basic An Introduction <OPTION value= vbdev>Visual Basic Application Development </OPTGROUP> </SELECT>
Faculty Computer Science Engineering
SELECTION LIST
optgroup
TEXTAREA
TextArea: is the Text box that user can input multi line. <TextArea Name=name Rows=n Cols=m Wrap>Default text </textarea> Textarea Attributes
NAME - Name of the variable to be processed by the form processing script. COLS - The number of columns within the text area. ROWS - The number of rows within the text area.
Wrap: virtual,physical
Faculty Computer Science Engineering
TEXTAREA
Example: <form> Comments ? <textarea rows=4 cols=50 name=comments> </textarea> </form>
FIELDSET
The <fieldset> Group related elements in a form. The <fieldset> tag draws a box around the related form elements. <Fieldset> <Legend Align=left, right>Ch thch </Legend> The elements in group </Fieldset> The <legend> tag defines a caption for the fieldset element.
Faculty Computer Science Engineering
FIELDSET
<FORM > <FIELDSET> <LEGEND>Position</LEGEND> Application for the post of: <INPUT name= 'name' type= 'text' tabindex= '1'> </FIELDSET> <FIELDSET> <LEGEND>Educational Qualifications</LEGEND> <INPUT name= 'qualif' type='radio' value= 'grad' tabindex= '5'> Graduate <INPUT name= 'qualif' type='radio' value='postgrad' tabindex='5'> Postgraduate </FIELDSET></FORM>
Faculty Computer Science Engineering
Faculty Computer
KEYBOARD ATTRIBUTES
Accesskey: Specifies a keyboard shortcut to access an element. Create: Accesskey= character. Used: Alt+ character Tabindex: Specifies the tab order of an element. Tabindex= number
Faculty Computer