MODULE 2 β Forms & User Input
π Lesson 2.7 β Mini Project: College Admission Form
π« Building a Complete Real-World Admission Form Using HTML
π― Learning Objectives
After completing this lesson, students will be able to:
β Create a Complete Admission Form
β Use All Form Elements Together
β Apply Form Validation
β Create Professional Form Layouts
β Build Real College Admission Forms
β Understand Real-World Form Design
π Introduction
Congratulations! π
You have learned:
β Form Basics
β Input Types
β Radio Buttons
β Checkboxes
β Dropdown Menus
β Text Areas
β Form Validation
Now it’s time to build a complete project.
π What is a College Admission Form?
A College Admission Form is used to collect information from students who want admission.
It collects:
- Personal Details
- Educational Details
- Contact Information
- Course Preferences
π― Information Required
Our Admission Form will collect:
β Student Name
β Father’s Name
β Mother’s Name
β Email Address
β Mobile Number
β Date of Birth
β Gender
β Category
β Course Selection
β Skills
β Address
ποΈ Admission Form Structure
--------------------------------
COLLEGE ADMISSION FORM
--------------------------------
Student Name
Father Name
Mother Name
Email
Mobile Number
Date of Birth
Gender
Category
Course Selection
Skills
Address
Submit Button
Reset Button
--------------------------------
π» Complete College Admission Form
<!DOCTYPE html>
<html>
<head>
<title>College Admission Form</title>
</head>
<body>
<h1>College Admission Form</h1>
<form>
<label>Student Name:</label>
<br>
<input
type="text"
placeholder="Enter Student Name"
required>
<br><br>
<label>Father's Name:</label>
<br>
<input
type="text"
placeholder="Enter Father's Name"
required>
<br><br>
<label>Mother's Name:</label>
<br>
<input
type="text"
placeholder="Enter Mother's Name"
required>
<br><br>
<label>Email Address:</label>
<br>
<input
type="email"
placeholder="Enter Email Address"
required>
<br><br>
<label>Mobile Number:</label>
<br>
<input
type="tel"
pattern="[0-9]{10}"
placeholder="10 Digit Mobile Number"
required>
<br><br>
<label>Date of Birth:</label>
<br>
<input
type="date"
required>
<br><br>
<label>Gender:</label>
<br>
<input
type="radio"
name="gender"
value="Male">
Male
<br>
<input
type="radio"
name="gender"
value="Female">
Female
<br>
<input
type="radio"
name="gender"
value="Other">
Other
<br><br>
<label>Category:</label>
<br>
<select required>
<option value="">
Select Category
</option>
<option>General</option>
<option>OBC</option>
<option>SC</option>
<option>ST</option>
<option>EWS</option>
</select>
<br><br>
<label>Course Applied For:</label>
<br>
<select required>
<option value="">
Select Course
</option>
<option>Diploma CSE</option>
<option>Diploma Mechanical</option>
<option>Diploma Civil</option>
<option>Diploma Electrical</option>
<option>Diploma Electronics</option>
</select>
<br><br>
<label>Skills:</label>
<br>
<input type="checkbox">
Computer Basics
<br>
<input type="checkbox">
MS Office
<br>
<input type="checkbox">
Programming
<br>
<input type="checkbox">
Internet Knowledge
<br><br>
<label>Address:</label>
<br>
<textarea
rows="5"
cols="40"
placeholder="Enter Full Address">
</textarea>
<br><br>
<input
type="submit"
value="Submit Application">
<input
type="reset"
value="Clear Form">
</form>
</body>
</html>
π― Expected Output
College Admission Form
Student Name
Father’s Name
Mother’s Name
Mobile Number
Date of Birth
Gender
Category
Course Selection
Skills
Address
Submit Application Button
Clear Form Button
π Adding Educational Details
You can improve the form by adding:
<label>10th Percentage:</label>
<br>
<input
type="number"
min="0"
max="100">
<br><br>
<label>School Name:</label>
<br>
<input
type="text">
<br><br>
π Adding Upload Fields
Students can upload documents.
<label>Upload Photo:</label>
<br>
<input type="file">
<br><br>
<label>Upload Marksheet:</label>
<br>
<input type="file">
π― Complete Admission Process Flow
Student Opens Form
β
Fills Details
β
Selects Course
β
Uploads Documents
β
Clicks Submit
β
Admission Data Stored
π« Real World Example
Forms similar to this are used by:
- Polytechnic Colleges
- Engineering Colleges
- Universities
- Coaching Institutes
- Training Centers
π Professional Improvements
Later using CSS we can add:
β Colors
β Borders
β Backgrounds
β Professional Layout
β Responsive Design
β οΈ Common Beginner Mistakes
Mistake 1
Not Using Required Fields
Wrong:
<input type="text">
Correct:
<input
type="text"
required>
Mistake 2
Using Text Instead of Email
Wrong:
<input type="text">
Correct:
<input type="email">
Mistake 3
Using Different Names for Radio Buttons
Wrong:
<input type="radio" name="a">
<input type="radio" name="b">
Correct:
<input type="radio" name="gender">
<input type="radio" name="gender">
π Best Practices
β Use Labels
β Use Validation
β Use Dropdown Menus
β Use Text Areas
β Use Proper Input Types
β Organize Form Fields Properly
π Final Mini Project Challenge
Create your own:
Polytechnic Admission Form
Include:
β Student Details
β Parent Details
β Contact Details
β Course Selection
β Educational Details
β Address
β Submit Button
π Practical Activity
Create a complete admission form for your Polytechnic College.
Add:
- Student Name
- Father Name
- Mother Name
- Mobile
- Gender
- Category
- Branch
- Skills
- Address
Run in Chrome Browser.
π Assignment
Assignment 2.7
- What is a College Admission Form?
- Why is validation important?
- Which tag creates dropdown menus?
- Which tag creates text areas?
- Which input type uploads files?
- Create a complete admission form.
- Add educational details and document upload fields.
π§ Quiz
Q1. Which input type uploads files?
A. text
B. upload
C. file
D. document
β Answer: C
Q2. Which tag creates dropdown menus?
A. <option>
B. <select>
C. <list>
D. <menu>
β Answer: B
Q3. Which tag creates multi-line text fields?
A. <input>
B. <text>
C. <textarea>
D. <area>
β Answer: C
Q4. Which attribute makes a field mandatory?
A. validate
B. required
C. check
D. verify
β Answer: B
Q5. Which input type validates email format?
A. text
B. mail
C. email
D. address
β Answer: C
π Module 2 Summary β Forms & User Input
You have successfully learned:
β Lesson 2.1 β Introduction to Forms
β Lesson 2.2 β Input Types
β Lesson 2.3 β Radio Buttons & Checkboxes
β Lesson 2.4 β Select Menu & Text Areas
β Lesson 2.5 β Form Validation Basics
β Lesson 2.6 β Building a Registration Form
β Lesson 2.7 β Mini Project: College Admission Form