Ex No:4 Date:: Design A Registration Form and Perform Form Validation Using Javascript
Ex No:4 Date:: Design A Registration Form and Perform Form Validation Using Javascript
<!DOCTYPE html>
<html>
<head>
<title>Login Check</title>
<style>
header {
text-align:center;
height: 100px;
padding: 10px;
}
footer {
text-align:center;
font-size: 12px;
height: 50px;
line-height: 50px;
padding: 10px;
border-radius: 10px;
</style>
<script type="text/javascript">
function check_login()
username = "srisanth";
password = "srisanth12";
usr = document.getElementById("txtusr").value;
pwd = document.getElementById("txtpwd").value;
window.location.href = "java.html";
else
alert("Invalid Username/Password");
}
</script>
</head>
<body>
<header>
</header>
<hr>
<table>
<tr>
<td>Username:</td>
</tr>
<tr>
<td>Password:</td>
</tr>
<tr>
</tr>
</table>
<footer>
Developed by srisanth
</footer>
</body>
</html>
MAIN.HTML
PAGE
JAVA.HTML:
<!DOCTYPE html>
<html>
<head>
<title>Homepage</title>
<style>
header {
text-align:center;
height: 100px;
padding: 10px;
footer {
text-align:center;
font-size: 12px;
height: 50px;
line-height: 50px;
padding: 10px;
border-radius: 10px;
}</style>
</head>
<body>
<header>
<h1>Welcome</h1>
</header> <hr>
<h1>Login Successful</h1>
<footer>
Developed by Srisanth</footer>
</body>
</html>
JAVA.HTML PAGE:
RESULT:
Thus the program executed and verified and successfully