Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- sample page
- </title>
- <script>
- function check()
- {
- var username = document.getElementById("name").value;
- var password = document.getElementById("pswd").value;
- if(username==""&&password=="")
- {
- alert("enter valid information");
- }
- else
- {
- alert("username:"+username);
- alert("password:"+password);
- }
- }
- </script>
- </head>
- <body>
- <center>
- <P><h1>srkr college</h1></p>
- username:
- <input type="text" id="name"/><br><br>
- password:
- <input type="password" id="pswd"/><br><br>
- <button type="submit" onclick="check()">login</button>
- </center>
- </body>
- </html>
Add Comment
Please, Sign In to add comment