PDA

View Full Version : cs101 fall 2010 2 assignment solution



Xpert
11-13-2010, 03:29 AM
You are required to design an Admission form for educational website in HTML.
(15 Marks)


Admission page will have three main parts



Header
Content
Footer



Header




Header contains any heading representing your form, you should write Admission Form there and you may use any image/background color behind the heading.

Content
http://2.bp.blogspot.com/__M5L-C3oo0s/TN2F3xi7lPI/AAAAAAAAAIU/IsqTNnVrpfI/s1600/cs101.JPG
The content section will contain three sub sections



Biodata
Education
Degree Program

Combo Box of Highest Education has these values in it:
- BBA
- B.A.
- BSIT
- BCS
- MBA
- MCS

Combo Box of Program Applied For has these values in it:
- MS (CS)
- MS (BA)
- MCS
- MBA
- BCS
- BBA
The complete Web page Preview
http://4.bp.blogspot.com/__M5L-C3oo0s/TN2F37iZhwI/AAAAAAAAAIM/Njr59M_zY7Q/s1600/cs101%2B2.JPG

Xpert
11-14-2010, 11:53 PM
Dear fellow here's the solution check your self

<HTML>
<HEAD>
<TITLE>New User Registartion form</TITLE>
<SCRIPT>
function checkForm(){
if (document.login.user.value.length < 1) {
window.alert('Empty fields Found!! Please Fill empty fields');
}
else if (document.login.user.value.length > 1) {
window.alert('All Fields are entered');
}
}
function checkForm(){
if (document.login.password.value.length < 1) {
window.alert('Empty fields Found!! Please Fill empty fields');
}
else if (document.login.password.value.length > 1) {
window.alert('All Fields are entered');
}
}
</SCRIPT>
</HEAD>
<BODY>
<FORM name="login" method="post" action=loginScriptURL>
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tr>
<th align ="left"rowspan="2"><img src="http://icwdic.webcontent-m1.com/m1/res/resource/contest_logos/vu_logo.PNG" width="141" height="88" /></th><td align ="right"><font color ="red"><b>Already a user Login here !!!</b></font>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
</tr>
<tr>
<td align="right">User Name<input type="text" name="user" size="20">
password <input type="password" name="password" size="10" maxlength="7">
<INPUT type="submit" name="login" value="login"
onMouseOver="checkForm()">
</TD></TR></TABLE><table border="1" bordercolor="lightblue"cellpadding="0" cellspacing="0" width="100%">
<tr>
<td width="100%" bgcolor="Darkblue"><font color="white"><b>Personal Information</b></font></td>
</tr></table></FORM>
<FORM name="submit" method="post" action=submitScriptURL>
<table border="1" bordercolor="lightblue"cellpadding="0" cellspacing="0" width="100%">
<tr><td width="30%">Name</td><td><input type="text" name="user" size="20"></td></tr>
<tr><td width="30%">Father's name</td><td><input type="text" name="fathername" size="20"></td></tr>
<tr><td width="30%">Address</td><td><textarea name="message" cols="20" rows="2"></textarea></td></tr>
<tr><td width="30%">Upload picture</td><td><input name="fileupload" id="fileupload" type="file">
</td></tr>
</table>


<table border="1" bordercolor="lightblue"cellpadding="0" cellspacing="0" width="100%">
<tr>
<td width="100%" bgcolor="Darkblue"><font color="white"><b>Account Information</b></font></td>
</tr></table>
<table border="1" bordercolor="lightblue"cellpadding="0" cellspacing="0" width="100%">
<tr><td width="30%">Email</td><td><input type="text" name="email" size="20"></td></tr>
<tr><td width="30%">Password</td><td><input type="password" name="password" size="20" maxlength="7"><b><font color="red">7 characters only*</font></b></td></tr>
<tr><td width="30%">Confirm password</td><td><input type="password" name="cpassword" size="20" maxlength="7"><b><font color="red">7 characters only*</font></b></td></tr>
</table>


<table border="1" bordercolor="lightblue"cellpadding="0" cellspacing="0" width="100%">
<tr>
<td width="100%" bgcolor="Darkblue"><font color="white"><b>Qualification</b></font></td>
</tr></table>
<table border="1" bordercolor="lightblue"cellpadding="0" cellspacing="0" width="100%">
<tr><td width="30%">Highest Degree</td><td><select name"degree"><option value"select" selected> ---Select---
<option value"Phd">Phd
<option value"Masters degree">Masters degree
<option value"Bachelors Degree">Bachelors Degree
<option value"Intermediate">Intermediate
</select></td></tr>
<tr><td width="30%">College/University</td><td><input type="text" name="cvname" size="20"></td></tr>
<tr><td width="30%">Status</td><td><input type="radio" name="complete" value="complete" checked>Completed
<input type="radio" name="Continued" value="Continued">Continued</td></tr>
<tr><td width="30%">Degrees achieved</td><td><input type="checkbox" value="PHD">PHD<br>
<input type="checkbox" value="MPhil">MPhil<br>
<input type="checkbox" value="Masters">Masters<br>
<input type="checkbox" value="Bachelors">Bachelors<br>
<input type="checkbox" value="Intermediate">Intermediate<br>
<input type="checkbox" value="Matriculation">Matriculation </td></tr>
<tr><td width="30%"></td><td><input type="submit"name="reg" value="Register"><input type="reset" value="Reset"></td></tr>
</table>
<br>
<table border="1" bordercolor="lightblue"cellpadding="0" cellspacing="0" width="100%">
<tr>
<td width="100%" bgcolor="Darkblue" align="center"><font color="white"><b>2010 All Rights reserved</b></font></td>

Xpert
11-14-2010, 11:57 PM
Another code which is helpful please make changes.

<html> <head> <title>Student admission form: Student ID: Your VU ID</title>
<script language="javascript" type="text/javascript">
function checkForm(){
if (document.regForm.one.value.length < 1){
alert("Empty Form field...! Please fill.");
return false;
}
if (document.regForm.two.value.length < 1){
alert("Empty Form field...! Please fill.");
return false;
}
if (document.regForm.three.value.length < 1){
alert("Empty Form field...! Please fill.");
return false;
}
if (document.regForm.four.value.length < 1){
alert("Empty Form field...! Please fill.");
return false;
}
return true;
}
</script>
</head>
<body background="C:\WINDOWS\Web\Wallpaper\Crystal.jpg" >
<form name="regForm" action="http://www.vu.edu.pk" method="post" onSubmit="return checkForm()">
<table border="0" align="center">
<tr><td align="center" bgcolor="sky blue" width="800" colspan="text">
<font color="white"><b>ADMISSION FORM</b></font></td></tr></table>
<table border="1" bordercolor="sky blue" align="center" bgcolor="white">
<tr><td colspan="2" align="left" bgcolor="sky blue" width="800">
<font color="white"><b>BIO-DATA</b></font></td></tr>
<tr><td align="left" width="30%"><b>Candidate's Name : </b></td>
<td width="70%">
<input type="text" align="left" name="one" size="20" maxlength="25"><b><font color="red">
Max. character limit is 25 </font></b></td></tr>
<tr><td align="left" width="30%"><b>Father's Name : </b></td>
<td width="70%"><input type="text" align="left" name="two" size="20" maxlength="25"><b><font color="red">
Max. character limit is 25 </font></b></td></tr>
<tr><td valign="top" width="30%"><b>Postal-Address : </b></td>
<td width="70%"><textarea name="three" cols="30" rows="3"></textarea><b><font color="red"></td></tr>
<tr><td align="left" width="30%"><b>Upload Your CV : </b></td>
<td width="70%"><input type="file" name="four" value="Browse" enctype="multipart"></td></tr>
<tr><td colspan="2" align="left" bgcolor="sky blue" width="800">
<b><font color="white">EDUCATION</b></font></td></tr>
<tr><td align="left" width="30%"><b>Highest Education : </b></td><td width="70%">
<select name="H.E">
<option selected> --- Click to Select --- </option>
<option>BBA</option>
<option>B.A</option>
<option>BS(IT)</option>
<option>BCS</option>
<option>MBA</option>
<option>MCS</option>
</select></td></tr>
<tr><td valign="top" width="30%"><b>GRADE : </b></td>
<td width="70%"><input type="radio" name="radio">A+<br>
<input type="radio" name="radio">A<br>
<input type="radio" name="radio">B+<br>
<input type="radio" name="radio">B<br>
<input type="radio" name="radio">C+<br>
<input type="radio" name="radio">C<br>
</td></tr>
<tr><td colspan="2" align="left" bgcolor="sky blue" width="800">
<font color="white"><b>DEGREE PROGRAMME</b></font></td></tr>
<tr><td width="30%"><b>Program Applied for: </b></td><td width="70%">
<select name="applied">
<option selected> --- Click to Select --- </option>
<option>MS(CS)</option>
<option>MS(BA)</option>
<option>MCS</option>
<option>MBA</option>
<option>BCS</option>
<option>BBA</option>
</select></td></tr>
<tr><td valign="top" width="30%"><b>Session Applied for : </b></td>
<td width="70%">
<input type="checkbox" name="check">Morning<br>
<input type="checkbox" name="check">Afternoon<br>
<input type="checkbox" name="check">Evening<br>
</td></tr>
<tr><td align="left" width="30%"></td>
<td width="70%"><input type="submit" name="regForm" value="Submit" >
<input type="reset"></td></tr>
<table border="0" align="center">
<tr><td align="center" bgcolor="sky blue" width="800" colspan="text">
</table> </form> </body> </html>