1600 PMP mock questions 1400 CAPM mock questions 800 SCJP 6 mock questions 600 OCAJP 7 mock questions 590 OCPJP 7 mock questions 556 SCWCD 5 mock questions 500 OCEJWCD 6 mock questions pdfDownload (java,struts, hibernet etc)

Java Script Tutorials

Form_as_anArray javascript

<html>
<head><title>Form</title></head>
<body>
<h2 align="center">Using form</h2><hr>
<form>
Name :-<Input type="text" name="text1" size="15"><br><br>
Password :-<Input type="Password" Name="pass1" size="8"><br><br>
</form>
<hr>
<form>
Hobbies :-<Input type="checkbox" name="check1" value="reading" checked>Reading
<Input type="checkbox" name="check1" value="music">Music
<Input type="checkbox" name="check1" value="trekking">Trekking
</form>
<hr>
<form>
<Input type="radio" name="radio1" value="male" checked>Male
<Input type="radio" name="radio1" value="female">Female<br><br>
<Input type="button" name="but1" value="click here"><br>
</form>
<script language="javascript">
    len=document.forms.length
    document.write("<pre>")
    document.write("There are "+len+" form in this document"+"\n\n")
    document.write("<hr>\n")
    for(i=0;i<len;i++)
    {
    num=document.forms[i].elements.length
    document.write("Form "+i+" has "+num+" elements\n\n")
    for(j=0;j<num;j++)
    {
    document.write("forms["+i+"].elements["+j+"]="+document.forms[i].elements[j].type+"\n")
    }
    document.write("<hr>\n")
    }
    document.write("</pre>")
</script>
</body>
</html>



Reviews and Comments


PMP, CAPM, PMI is a registered certification mark of the Project Management Institute, Inc

Copyright © www.techfaq360.com 2016


About US | Contact US | Privacy Policy | Terms and Conditions  | Website disclaimer  | Cancellation and Refund Policy  | Shipping & Delivery Policy