corresponds to the form target attributebull text


Corresponds to the FORM TARGET attribute.

• Text - It is an object representing a text field.

• Text area - It is an object representing a text area field. Some of the Form Element Properties are:

• Name - It provides access to an element's name attribute. It applies to all of the form elements.

• Type - it is for identifies the object's type. It applies to every form elements.

• Value - it is for identifies object's value. It applies to all checkbox, hidden, button radio, submit, password, reset, text or textarea.

• Checked - This is for identifies whether the element is checked. It applies to checkbox & radio only.

• Default checked - This is for identifies whether the element is checked by default. This applies to checkbox & radio only.

• Default value - it is for identifies the object's default value. It applies to submit, password and textarea.

• Length - This is for identifies the length of a select list. This applies to select.                                             

• Options - An array which identifies the options supported by the select list. It applies to select.

Syntax : <FORM Name = "myform" Action = "mailto:[email protected]" Method               

= POST Ectype = "multipart/form-data" on submit = "return check ( )" >                                  

<HTML>                                                                                                                                           

<HEAD>

<SCRIPT LANGUAGE = "javascript">                                                                                         

function check ()                                                                                                                               

{ if (document.myform.email.value  == "") {

alert("please enter your email-id");                                                                       

return false; }                                                                                                         

}                                                                                                                                            

</SCRIPT>                                                                                                                                       

</HEAD>                                                                                                                                           

<BODY>                                                                                                                                          

Enter your Email to subscribe : <p>                                                                                                

<FORM Name = "myform" Action = "mailto:[email protected]" Method = POST

Enctype = "multipart/form-data" onsubmit = "return check()" >                                                   

<Input type = "text" Name = "email">                                                                              

<Input type = "submit" value = "submit">                                                                        

</FORM>                                                                                                                                         

</BODY>                                                                                                                                          

</HTML>                                                                                                                                         

 

The above code is utilized for obtaining the user's email-id. In case the user clicks on to the submit button without entering the email-id in the wanted text field, he sees a message box represent ting that the email-id has not been entered.

Request for Solution File

Ask an Expert for Answer!!
PHP Web Programming: corresponds to the form target attributebull text
Reference No:- TGS0416506

Expected delivery within 24 Hours