master
Caleb Fontenot 2023-03-14 09:47:00 +07:00
parent bea3068292
commit 512bd81c21
4 changed files with 60 additions and 0 deletions

BIN
.DS_Store vendored

Binary file not shown.

@ -0,0 +1,31 @@
<!DOCTYPE html>
<!--
Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license
Click nbfs://nbhost/SystemFileSystem/Templates/ClientSide/html.html to edit this template
-->
<html>
<head>
<title>Blastoff</title>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<script>
function sleep(ms) {
return new Promise(resolve => setTimeout(resolve, ms));
}
async function countdown() {
var countdownLength = 5;
for (let i = countdownLength; i > 0; i--) {
document.write("Countdown in " + i + "..." + "<br>");
await sleep(1000);
}
document.write("BLASTOFF!");
}
</script>
</head>
</html>
<body>
<button id="countdown" onclick="countdown();">Start Countdown</button>
</body>

@ -0,0 +1,29 @@
<!DOCTYPE html>
<!--
Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license
Click nbfs://nbhost/SystemFileSystem/Templates/ClientSide/html.html to edit this template
-->
<html>
<head>
<title>Password Entry</title>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<script>
//document.body.innerHTML = "a"; // Clear document contents
var password = "";
var promptString = "Please enter a password. Your password must be at minimum 8 characters in length.";
var timesLooped = 0;
do {
if (timesLooped === 1) {
promptString += " Password is under minimum length.";
}
password = prompt(promptString);
timesLooped++;
} while (password.length < 8);
document.write("Password meets criteria. Password accepted!");
</script>
</head>
<body>
</body>
</html>