forked from tmate/tmate.github.io
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy path404.html
More file actions
36 lines (31 loc) · 973 Bytes
/
404.html
File metadata and controls
36 lines (31 loc) · 973 Bytes
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
---
layout: page
title: 404
---
<script type="text/javascript">
function endsWith(str, suffix) {
return str.indexOf(suffix, str.length - suffix.length) !== -1;
}
var path = window.location.pathname;
if (endsWith(path, '/index.html')) {
path = path.substring(0, path.length - '/index.html'.length);
}
if (endsWith(path, '/')) {
path = path.substring(0, path.length - 1);
}
console.log('processing not found path: ' + path);
if (path == '/eap' || path == '/eap.html') {
window.location.pathname = '/download.html';
} else if (
endsWith(path, '/download') ||
endsWith(path, '/documentation') ||
endsWith(path, '/support') ||
endsWith(path, '/contacts') ||
endsWith(path, '/pricing')) {
window.location.pathname = path + '.html';
} else if (path == '/register' || path == '/register.html') {
window.location.pathname = '/pricing.html';
} else {
window.location.hostname = 'old.subgit.com';
}
</script>