Adl Exp3
Adl Exp3
Adl Exp3
<html>
<head>
<style>
body {
background-color: pink;
.container {
padding-top: 10px;
padding-right: 50px;
padding-bottom: 50px;
padding-left: 50px;
background-color: lightblue;
width: 100%;
padding: 15px;
display: inline-block;
border: none;
background: #f1f1f1;
input[type=text]:focus, input[type=password]:focus {
background-color: orange;
outline: none;
div {
padding: 10px 0;
hr {
border: 1px solid #f1f1f1;
margin-bottom: 25px;
.registerbtn {
background-color: #4CAF50;
color: white;
margin: 8px 0;
border: none;
cursor: pointer;
width: 100%;
opacity: 0.9;
.registerbtn:hover {
opacity: 1;
.error {
color: red;
</style>
</head>
<body>
<div class="container">
<hr>
<label>
<b>Course</b>
</label>
<option value="BCA">BCA</option>
<option value="BBA">BBA</option>
<option value="B.Tech">B.Tech</option>
<option value="MBA">MBA</option>
<option value="MCA">MCA</option>
<option value="M.Tech">M.Tech</option>
</select>
<label>
<b>Gender</b>
</label>
<label for="email"><b>Email</b></label>
<label for="password"><b>Password</b></label>
</form>
<script>
function validateForm() {
errorElement.textContent = "";
if (!first_name.match(nameRegex)) {
isValid = false; }
if (!last_name.match(nameRegex)) {
isValid = false; }
isValid = false; }
if (!email.match(emailRegex)) {
isValid = false; }
if (!password.match(passwordRegex)) {
isValid = false; }
if (isValid) {
alert("Registration successful!"); }
return isValid; }
</script>
</body>
</html>