-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
37 lines (30 loc) · 1.12 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
<!DOCTYPE html>
<html lang="pt-BR">
<head>
<meta charset="UTF-8">
<title>Hello World</title>
</head>
<body>
<p id="connection"></p>
<p id="connectionDetail"></p>
<p id="mozConnection"></p>
<p id="webkitConnection"></p>
<script>
if ('connection' in navigator) {
document.getElementById("connection").innerText = "Contem 'connection' in navigator"
}else{
document.getElementById("connection").innerText = "Nao contem 'connection' in navigator"
}
if ('mozConnection' in navigator) {
document.getElementById("mozConnection").innerText = "Contem 'mozConnection' in navigator"
}else{
document.getElementById("mozConnection").innerText = "Nao contem 'mozConnection' in navigator"
}
if ('webkitConnection' in navigator) {
document.getElementById("webkitConnection").innerText = "Contem 'webkitConnection' in navigator"
}else{
document.getElementById("webkitConnection").innerText = "Nao contem 'webkitConnection' in navigator"
}
</script>
</body>
</html>