forked from ev3lessons/FLL-Tutorials
-
Notifications
You must be signed in to change notification settings - Fork 0
/
404.html
98 lines (75 loc) · 2.74 KB
/
404.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
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
---
layout: en/default
---
<script>
langs=['{{ site.all_langs | join: "', '" }}']
function get_browser_version(){
var N=navigator.appName, ua=navigator.userAgent, tem;
var M=ua.match(/(opera|chrome|safari|firefox|msie)\/?\s*(\.?\d+(\.\d+)*)/i);
if(M && (tem= ua.match(/version\/([\.\d]+)/i))!= null) M[2]= tem[1];
M=M? [M[1], M[2]]: [N, navigator.appVersion, '-?'];
return M[1];
}
function getParameterByName(name, url) {
if (!url) url = window.location.href;
name = name.replace(/[\[\]]/g, "\\$&");
var regex = new RegExp("[?&]" + name + "(=([^&#]*)|&|#|$)"),
results = regex.exec(url);
if (!results) return null;
if (!results[2]) return '';
return decodeURIComponent(results[2].replace(/\+/g, " "));
}
var browser = navigator.appName;
var version = get_browser_version();
if (browser=="Microsoft Internet Explorer") {
if (version<="8.0")
document.location.href="http://classic.ev3lessons.com/"
}
if (getParameterByName('lang') != null) {
var language = getParameterByName('lang');
} else if (localStorage.lang) {
var language = localStorage.lang.split('ev3cookie');
} else if (window.location.hash) {
var language = window.location.hash.substring(1);
} else {
var language = navigator.language.split('-')[0];
}
localStorage.lang = language;
if (language == "en-us") {
language = "en";
} else if (language == "pt-br") {
language = "pt";
} else if (language == "br") {
language = "pt";
}
if ((String(langs).indexOf(language+":")) == -1) {
language = "en";
}
page = window.location.href.split('/')[3].split('?')[0].split('#')[0];
if (page == "RobotGame.html") {
window.location.href = "/"+language+"/RobotGame.html"
} else if (page == "CoreValues.html") {
window.location.href = "/"+language+"/CoreValues.html"
} else if (page == "Project.html") {
window.location.href = "/"+language+"/Project.html"
} else if (page == "Worksheets.html") {
window.location.href = "/"+language+"/Worksheets.html"
} else if (page == "ResourceArchive.html") {
window.location.href = "/"+language+"/ResourceArchive.html"
} else if (page == "CoachCorner.html") {
window.location.href = "/"+language+"/CoachCorner.html"
} else if (page == "HallOfFame.html") {
window.location.href = "/"+language+"/HallOfFame.html"
} else if (page == "corevalues") {
file = window.location.href.split("/corevalues/")[1]
window.location.href = "/"+language+"/corevalues/"+file
} else if (page == "coachcorner") {
file = window.location.href.split("/coachcorner/")[1]
window.location.href = "/"+language+"/coachcorner/"+file
}
</script>
<div class="container">
<h1>404</h1>
<p><strong>Page not found :(</strong></p>
<p>The requested page could not be found.</p>
</div>