HOME BLOG PORTFOLIO PHOTO CONTACT
javascript div dualbutton code example

javascript div dualbutton code example:

For trial Click here :

For Code Copy Below as dual.html save:

{code type=codetype}

<html>
<head>
<meta http-equiv=”Content-Type” content=”text/html; charset=iso-8859-1″>
<title>jay bharat, dualbutton code example</title>
<script type=”text/javascript”>
function toggle(theDiv)
{
document.getElementById(“q1″).style.display = “none”;
document.getElementById(“q2″).style.display = “none”;
document.getElementById(“q3″).style.display = “none”;
document.getElementById(“q4″).style.display = “none”;
document.getElementById(“q5″).style.display = “none”;
document.getElementById(“q6″).style.display = “none”;
document.getElementById(“q7″).style.display = “none”;
document.getElementById(“q8″).style.display = “none”;
document.getElementById(theDiv).style.display = “block”;
}
</script>
<style type=”text/css”>
#q1, #q2, #q3, #q4, #q5, #q6, #q7, #q8
{
DISPLAY: none;
}
</style>

</head>

<body>

<table width=”100%” border=”0″>

<tr>
<td onClick=”toggle(‘q1′);” > <a href=”javascript:void(null)”>q1</a></td>
<td onClick=”toggle(‘q2′);” ><a href=”javascript:void(null)”> q2</a></td>
<td onClick=”toggle(‘q3′);” ><a href=”javascript:void(null)”> q3</a></td>
<td onClick=”toggle(‘q4′);” ><a href=”javascript:void(null)”> q4</a></td>
<td onClick=”toggle(‘q5′);” ><a href=”javascript:void(null)”> q5</a></td>
<td onClick=”toggle(‘q6′);” ><a href=”javascript:void(null)”> q6</a></td>
<td onClick=”toggle(‘q7′);” ><a href=”javascript:void(null)”> q7</a></td>
<td onClick=”toggle(‘q8′);” ><a href=”javascript:void(null)”> q8</a></td>
</tr>
</table>

<!–q1 start–><div id=”q1″>
<br>
<table width=”100%” border=”0″ cellpadding=”0″ cellspacing=”0″ align=”center”>
<tr>
<td align=”left” valign=”top” >1.Write a php programme to accept Name,FatherName,MotherName,Address,PhoneNumber and display it. </td>

</tr>
</table>
</div><!–q1 end–>

<!–q2 start–>
<div id=”q2″>
<br>
<table width=”100%” border=”0″ cellpadding=”0″ cellspacing=”0″ align=”center”>
<tr>
<td align=”left” valign=”top” >2.Write a php programme to generate table from 2 t0 20.</td>
</tr>
</table>
</div> <!–q2 end–>

<!–q3 start–>
<div id=”q3″>
<br>
<table width=”100%” border=”0″ cellpadding=”0″ cellspacing=”0″ align=”center”>
<tr>
<td align=”left” valign=”top” >3.Write a php Program to display number from 1 to 100 in new line.</td>
</tr>
</table>
</div> <!–q3 end–>

<!–q4 start–>
<div id=”q4″>
<br>
<table width=”100%” border=”0″ cellpadding=”0″ cellspacing=”0″ align=”center”>
<tr>
<td align=”left” valign=”top” >4.Accept two number from users and find out which number is greater.</td>
</tr>
</table>
</div> <!–q4 end–>

<!–q5 start–>
<div id=”q5″>
<br>
<table width=”100%” border=”0″ cellpadding=”0″ cellspacing=”0″ align=”center”>
<tr>
<td align=”left” valign=”top” >5.Write a php code two accept two peoples age and find out who is younger between them.</td>
</tr>
</table>
</div> <!–q5 end–>

<!–q6 start–>
<div id=”q6″>
<br>
<table width=”100%” border=”0″ cellpadding=”0″ cellspacing=”0″ align=”center”>
<tr>
<td align=”left” valign=”top” >6.Write a javascript code to form validation using js to accept name , fathername,email,phone and all field should not empty</td>
</tr>
</table>
</div> <!–q6 end–>

<!–q7 start–>
<div id=”q7″>
<br>
<table width=”100%” border=”0″ cellpadding=”0″ cellspacing=”0″ align=”center”>
<tr>
<td align=”left” valign=”top” >7.Write a javascript code to form validation using js to accept name , fathername,email,phone and all field should not empty and mail should be in mail format(abc@xyz.com), phone should be number(9844454)</td>
</tr>
</table>
</div> <!–q7 end–>

<!–q8 start–>
<div id=”q8″>
<br>
<table width=”100%” border=”0″ cellpadding=”0″ cellspacing=”0″ align=”center”>
<tr>
<td align=”left” valign=”top” >8.Write a javascript code to form validation using js to accept name , fathername,email,phone and all field should not empty and mail should be in mail format(abc@xyz.com), phone should be number(9844454) But not use document.form1.fieldname use like fieldid (take google help if need)</td>
</tr>
</table>
</div> <!–q8 end–>
</body>
</html>

{/code}

   Share on Facebook

Page views:16