Skip to content

Commit ab17ac7

Browse files
BOM-navigator
1 parent 7ab053d commit ab17ac7

File tree

3 files changed

+63
-0
lines changed

3 files changed

+63
-0
lines changed
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
<!DOCTYPE html>
2+
<html lang="en">
3+
4+
<head>
5+
<meta charset="UTF-8">
6+
<meta http-equiv="X-UA-Compatible" content="IE=edge">
7+
<meta name="viewport" content="width=device-width, initial-scale=1.0">
8+
<title>navigation-BOM</title>
9+
<link rel="stylesheet" href="style.css">
10+
</head>
11+
12+
<body>
13+
<h1>Navigation in BOM</h1>
14+
<button onclick="Display()">Navigate</button>
15+
<p id="textOne"></p>
16+
<script src="script.js"></script>
17+
</body>
18+
19+
</html>
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
let textOne = document.querySelector('#textOne');
2+
3+
function Display() {
4+
return (
5+
textOne.innerHTML =
6+
`
7+
<p>--> Windows Navigator: ${window.navigator}</p>
8+
<p>--> CookieEnabled: ${navigator.cookieEnabled}</p>
9+
<p>--> Navigator Language: ${navigator.language}</p>
10+
<p>--> Navigator userAgent: ${navigator.userAgent}</p>
11+
<p>--> Navigator onLine: ${navigator.onLine}</p>
12+
<p>--> Some of the navigation does not work for seecurity reasons like</p>
13+
<p>--> Navigator JavaEnabled: ${navigator.javaEnabled}</p>
14+
<p>--> Navigator Platform: ${navigator.platform}</p>
15+
<p>--> Navigator appVersion: ${navigator.appVersion}</p>
16+
<p>--> Navigator Product: ${navigator.product}</p>
17+
<p>--> Navigator appCodeName: ${navigator.appCodeName}</p>
18+
<p>--> Navigator appName: ${navigator.appName}</p>
19+
<p>--> and many others...</p>
20+
21+
22+
`
23+
);
24+
}
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
h1 {
2+
font-family: cursive;
3+
}
4+
5+
p {
6+
font-family: monospace;
7+
}
8+
9+
button {
10+
background-color: transparent;
11+
border: 2px solid rgb(15, 240, 15);
12+
border-radius: 5px;
13+
font-size: 20px;
14+
padding: 10px 20px;
15+
cursor: pointer;
16+
}
17+
18+
button:hover {
19+
background-color: rgb(15, 240, 15);
20+
}

0 commit comments

Comments
 (0)