<html>
<head>
<title>VIRTUAL UNIVERSITY OF PAKISTAN</title>
<script type="text/javascript">
function copyItem(item){
if(item == 'nam')
document.getElementById("name2").value = document.getElementById("name1").value;
else if(item == 'pas')
document.getElementById("pass2").value = document.getElementById("pass1").value;
else if(item == 'add')
document.getElementById("address2").value = document.getElementById("address1").value;
else if(item == 'loc')
document.getElementById("location2").value = document.getElementById("location1").value;
}
function checkItem(item){
if(item == 'nam' && (document.getElementById("name1").value == '')){
document.getElementById("name1").focus();
alert('Name field is empty');
}
else if(item == 'pas' && (document.getElementById("pass1").value == ''))
alert('Password field is empty');
else if(item == 'add' && (document.getElementById("address1").value == ''))
alert('Address field is empty');
else if(item == 'loc' && (document.getElementById("location1").value == ''))
alert('Location field is empty');
else if(item == 'sub' && (!myForm.***[0].checked)){
alert('Male is not selected');
return false;
}
}
</script>
</head>
<body bgcolor="gray">
<TABLE border="3" align="center" bgcolor="lightgray">
<tr>
<td align="center">
<a href="http://vulms.vu.edu.pk/" target="_blank"><img src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhvHut_HkDpXVqRCL4fT-inp1_B5oIPFOi4m5oteBZPj3q-1yR-NqLusb3ozjaVxJdObOIFdWpo1QftIlHloHpupsKfyL8hh-O_DWRqbZZht79v9bRxWs5kur_1-ZgYtuD9dBB8ZT3TpWo/s1600-r/vu_logo.png" width="150" alt="vu logo"></a>
</td>
</tr>
<tr><td align="center">
<br><b>CS101 ASSIGNMENT NO. 03</b><br>
</td></tr>
<tr width="25">
<td><br><FORM METHOD="POST" ACTION="http://vu.edu.pk/" name="myForm" onsubmit="return checkItem('sub')">
<TABLE BORDER="2" BORDERCOLOR="PINK" BORDERCOLORLIGHT="#33CCFF" BORDERCOLORDARK="#0000CC" ALIGN="CENTER"><tr>
<td width="70" height="35" align="right" valign="top">Name:</td>
<td align="left"><input type="Name" name="User" MAXLENGTH="10" SIZE="25" id="name1" onkeyup="copyItem('nam')" onblur="checkItem('nam')"></td>
<td align="left"><input type="Name" name="User" MAXLENGTH="10" SIZE="25" id="name2" VALUE="" DISABLED ></td>
</tr><tr>
<td width="70" height="35" align="right" valign="top">Password:</td>
<td align="left" valign="top"><input type="PASSWORD" name="pwd" MAXLENGTH="6" SIZE="25" id="pass1" onkeyup="copyItem('pas')" onblur="checkItem('pas')"></td>
<td align="left" valign="top"><input type="PASSWORD" name="pwd" MAXLENGTH="6" SIZE="25" id="pass2" VALUE="" DISABLED ></td>
</tr>
<tr width="20">
<td width="80" height="100" align="right" valign="top">Address:</td>
<td align="left" valign="top"><TEXTAREA Name="comments" rows="4" cols="19" id="address1" onkeyup="copyItem('add')" onblur="checkItem('add')"></TEXTAREA></td>
<td align="left" valign="top"><TEXTAREA Name="comments" rows="4" cols="19" id="address2" VALUE="Read Only Box by *****" DISABLED></TEXTAREA></td>
</tr>
<tr width="20">
<td width="100" height="30" align="right" valign="top">Gender:</td>
<td align="left" colspan="2">
<input type="radio" name="***" value="male" id="***"/> Male <input type="radio" name="***" value="female" CHECKED> Female</td>
</tr>
<tr width="20">
<td align="right" valign="top">Hobbies:</td>
<td>
<input type="checkbox" name="hobby" value="Cricket" /> Playing Cricket<br/>
<input type="checkbox" name="hobby" value="Internet" /> Surfing Internet<br/>
<input type="checkbox" name="hobby" value="Books" /> Reading Books
</td>
<td>
<input type="checkbox" name="hobby" value="Cricket" DISABLED /> Playing Cricket<br/>
<input type="checkbox" name="hobby" value="Internet" DisABLED /> Surfing Internet<br/>
<input type="checkbox" name="hobby" value="Books" DISABLED /> Reading Books
</td>
</tr>
<tr width="20">
<td width="80" height="110" align="right" valign="top">Location:</td>
<td width="90%" align="left" valign="top">
<div align="center">
<select name="mydropdown" id="location1" onchange="copyItem('loc')" onblur="checkItem('loc')">
<option value="">Select Location</option>
<option value="Virtual University Campus (SHADMAN), Lahore
1st Floor 1-Shadman Market Shadman
">Lahore</option>
<option value="Virtual University Campus, Karachi
A-21, KCHS, Near Duty Free Centre, Baloch Colony Bus Stop, Karachi
">Karchi</option>
<option value="Virtual University Campus, Islamabad. 9-E, Rizwan Plaza, Blue Area, Islamabad.">Islamabad</option>
<option value="Virtual University Campus, Multan
23/3, Officers Colony, 2nd & 3rd Floor, Near Chungi No. 9, Bosan Road, Multan
">Multan</option>
<option value="Virtual University Campus, Peshawar
8-Jamrud Road, P.O. Tehkal Bala, Adjacent Toyota Froniter Motors, Peshawar.
">Peshawar</option>
</select>
</div>
</td>
<td width="90%" align="left" valign="top"><TEXTAREA Name="comments" rows="4" cols="19" VALUE="" id="location2" disABLED></TEXTAREA></td>
</tr>
<tr><td> </td><td><input type="submit" value="Submit" /><input type="reset" value="Reset" /> </td></tr></tabale>
</form>
</body
</html>
<head>
<title>VIRTUAL UNIVERSITY OF PAKISTAN</title>
<script type="text/javascript">
function copyItem(item){
if(item == 'nam')
document.getElementById("name2").value = document.getElementById("name1").value;
else if(item == 'pas')
document.getElementById("pass2").value = document.getElementById("pass1").value;
else if(item == 'add')
document.getElementById("address2").value = document.getElementById("address1").value;
else if(item == 'loc')
document.getElementById("location2").value = document.getElementById("location1").value;
}
function checkItem(item){
if(item == 'nam' && (document.getElementById("name1").value == '')){
document.getElementById("name1").focus();
alert('Name field is empty');
}
else if(item == 'pas' && (document.getElementById("pass1").value == ''))
alert('Password field is empty');
else if(item == 'add' && (document.getElementById("address1").value == ''))
alert('Address field is empty');
else if(item == 'loc' && (document.getElementById("location1").value == ''))
alert('Location field is empty');
else if(item == 'sub' && (!myForm.***[0].checked)){
alert('Male is not selected');
return false;
}
}
</script>
</head>
<body bgcolor="gray">
<TABLE border="3" align="center" bgcolor="lightgray">
<tr>
<td align="center">
<a href="http://vulms.vu.edu.pk/" target="_blank"><img src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhvHut_HkDpXVqRCL4fT-inp1_B5oIPFOi4m5oteBZPj3q-1yR-NqLusb3ozjaVxJdObOIFdWpo1QftIlHloHpupsKfyL8hh-O_DWRqbZZht79v9bRxWs5kur_1-ZgYtuD9dBB8ZT3TpWo/s1600-r/vu_logo.png" width="150" alt="vu logo"></a>
</td>
</tr>
<tr><td align="center">
<br><b>CS101 ASSIGNMENT NO. 03</b><br>
</td></tr>
<tr width="25">
<td><br><FORM METHOD="POST" ACTION="http://vu.edu.pk/" name="myForm" onsubmit="return checkItem('sub')">
<TABLE BORDER="2" BORDERCOLOR="PINK" BORDERCOLORLIGHT="#33CCFF" BORDERCOLORDARK="#0000CC" ALIGN="CENTER"><tr>
<td width="70" height="35" align="right" valign="top">Name:</td>
<td align="left"><input type="Name" name="User" MAXLENGTH="10" SIZE="25" id="name1" onkeyup="copyItem('nam')" onblur="checkItem('nam')"></td>
<td align="left"><input type="Name" name="User" MAXLENGTH="10" SIZE="25" id="name2" VALUE="" DISABLED ></td>
</tr><tr>
<td width="70" height="35" align="right" valign="top">Password:</td>
<td align="left" valign="top"><input type="PASSWORD" name="pwd" MAXLENGTH="6" SIZE="25" id="pass1" onkeyup="copyItem('pas')" onblur="checkItem('pas')"></td>
<td align="left" valign="top"><input type="PASSWORD" name="pwd" MAXLENGTH="6" SIZE="25" id="pass2" VALUE="" DISABLED ></td>
</tr>
<tr width="20">
<td width="80" height="100" align="right" valign="top">Address:</td>
<td align="left" valign="top"><TEXTAREA Name="comments" rows="4" cols="19" id="address1" onkeyup="copyItem('add')" onblur="checkItem('add')"></TEXTAREA></td>
<td align="left" valign="top"><TEXTAREA Name="comments" rows="4" cols="19" id="address2" VALUE="Read Only Box by *****" DISABLED></TEXTAREA></td>
</tr>
<tr width="20">
<td width="100" height="30" align="right" valign="top">Gender:</td>
<td align="left" colspan="2">
<input type="radio" name="***" value="male" id="***"/> Male <input type="radio" name="***" value="female" CHECKED> Female</td>
</tr>
<tr width="20">
<td align="right" valign="top">Hobbies:</td>
<td>
<input type="checkbox" name="hobby" value="Cricket" /> Playing Cricket<br/>
<input type="checkbox" name="hobby" value="Internet" /> Surfing Internet<br/>
<input type="checkbox" name="hobby" value="Books" /> Reading Books
</td>
<td>
<input type="checkbox" name="hobby" value="Cricket" DISABLED /> Playing Cricket<br/>
<input type="checkbox" name="hobby" value="Internet" DisABLED /> Surfing Internet<br/>
<input type="checkbox" name="hobby" value="Books" DISABLED /> Reading Books
</td>
</tr>
<tr width="20">
<td width="80" height="110" align="right" valign="top">Location:</td>
<td width="90%" align="left" valign="top">
<div align="center">
<select name="mydropdown" id="location1" onchange="copyItem('loc')" onblur="checkItem('loc')">
<option value="">Select Location</option>
<option value="Virtual University Campus (SHADMAN), Lahore
1st Floor 1-Shadman Market Shadman
">Lahore</option>
<option value="Virtual University Campus, Karachi
A-21, KCHS, Near Duty Free Centre, Baloch Colony Bus Stop, Karachi
">Karchi</option>
<option value="Virtual University Campus, Islamabad. 9-E, Rizwan Plaza, Blue Area, Islamabad.">Islamabad</option>
<option value="Virtual University Campus, Multan
23/3, Officers Colony, 2nd & 3rd Floor, Near Chungi No. 9, Bosan Road, Multan
">Multan</option>
<option value="Virtual University Campus, Peshawar
8-Jamrud Road, P.O. Tehkal Bala, Adjacent Toyota Froniter Motors, Peshawar.
">Peshawar</option>
</select>
</div>
</td>
<td width="90%" align="left" valign="top"><TEXTAREA Name="comments" rows="4" cols="19" VALUE="" id="location2" disABLED></TEXTAREA></td>
</tr>
<tr><td> </td><td><input type="submit" value="Submit" /><input type="reset" value="Reset" /> </td></tr></tabale>
</form>
</body
</html>
No comments:
Post a Comment