Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <html>
- <title>Guess the number</title>
- <head>
- <SCRIPT LANGUAGE = "JavaScript">
- var username = window.prompt('Please insert your username', 'Zac');
- var password = window.prompt('Ok ' + username + ' please insert your password', '');
- if(username != 'Zac' && username != 'zac')
- {
- alert('Sorry that username cannot be found!, please try again');
- username = window.prompt('Please insert your username', 'Zac');
- password = window.prompt('Ok ' + username + ' please insert your password', '');
- }
- while(password != 'Mone50')
- {
- alert('Sorry that password isn\'t right, please try again');
- username = window.prompt('Please insert your username', 'Zac');
- password = window.prompt('Ok ' + username + ' please insert your password', '');
- }
- document.write('Welcome ' + username + ' you now have access');
- </script>
- </head>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement