Device Sync
This commit is contained in:
@@ -1,18 +1,18 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>Week 3 Class 1</title>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<h1>Week 3 Class 1</h1>
|
||||
<p>Enter some details</p>
|
||||
<input id="firstNameBox" type="text" placeholder="First Name">
|
||||
<input id="lastNameBox" type="text" placeholder="Last Name">
|
||||
<input id="ageBox" type="number" placeholder="Age">
|
||||
<input id="passwordBox" type="password" placeholder="Password">
|
||||
<button type="submit" onclick="showDetails()">Submit</button>
|
||||
<p id="detailsLabel">Entered Details: </p>
|
||||
<script src="index.js"></script>
|
||||
</body>
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>Week 3 Class 1</title>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<h1>Week 3 Class 1</h1>
|
||||
<p>Enter some details</p>
|
||||
<input id="firstNameBox" type="text" placeholder="First Name">
|
||||
<input id="lastNameBox" type="text" placeholder="Last Name">
|
||||
<input id="ageBox" type="number" placeholder="Age">
|
||||
<input id="passwordBox" type="password" placeholder="Password">
|
||||
<button type="submit" onclick="showDetails()">Submit</button>
|
||||
<p id="detailsLabel">Entered Details: </p>
|
||||
<script src="index.js"></script>
|
||||
</body>
|
||||
</html>
|
||||
@@ -1,14 +1,14 @@
|
||||
function showDetails() {
|
||||
var firstName = document.getElementById("firstNameBox").value;
|
||||
var lastName = document.getElementById("lastNameBox").value;
|
||||
var age = Number(document.getElementById("ageBox").value);
|
||||
var password = document.getElementById("passwordBox").value;
|
||||
console.log(`You entered: ${firstName}, ${lastName}, ${age}, ${password}`);
|
||||
document.getElementById("detailsLabel").innerHTML += `${firstName}, ${lastName}, ${age}, ${password}`;
|
||||
|
||||
console.log(10 + 10);
|
||||
console.log(10 * 10);
|
||||
console.log(10 - 3);
|
||||
console.log(100 / 25);
|
||||
console.log(100 % 3);
|
||||
function showDetails() {
|
||||
var firstName = document.getElementById("firstNameBox").value;
|
||||
var lastName = document.getElementById("lastNameBox").value;
|
||||
var age = Number(document.getElementById("ageBox").value);
|
||||
var password = document.getElementById("passwordBox").value;
|
||||
console.log(`You entered: ${firstName}, ${lastName}, ${age}, ${password}`);
|
||||
document.getElementById("detailsLabel").innerHTML += `${firstName}, ${lastName}, ${age}, ${password}`;
|
||||
|
||||
console.log(10 + 10);
|
||||
console.log(10 * 10);
|
||||
console.log(10 - 3);
|
||||
console.log(100 / 25);
|
||||
console.log(100 % 3);
|
||||
}
|
||||
Reference in New Issue
Block a user