Repository navigation
Expand file tree
/
Copy path404.html
More file actions
61 lines (53 loc) · 1.68 KB
/
Copy path404.html
File metadata and controls
61 lines (53 loc) · 1.68 KB
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
---
layout: default
title: Error!
permalink: /404
---
<!-- HEADER -->
{% include header.html with_signup_form='true' %}
<style>{% include css/404.css %}</style>
<div class="a404-Hero">
<h1><span class="code"></span> - Crash Landing! <span class="message"></span></h1>
<h1 class="mini"><span class="code"></span>Crash Landing!<br><span class="message"></span></h1>
<ul>
<li><a href="/" class="button">Go to home page</a></li>
<li><a href="/docs/home" class="button">Visit Help Center</a></li>
</ul>
</div>
<figure class="a404-Ground"></figure>
<script>
var entityMap = {
'&': '&',
'<': '<',
'>': '>',
'"': '"',
"'": ''',
'/': '/',
'`': '`',
'=': '='
};
function escapeHtml (string) {
return String(string).replace(/[&<>"'`=\/]/g, function (s) {
return entityMap[s];
});
}
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 error_code = window.location.pathname.split( '/' )[1];
var error_msg = getParameterByName("msg");
document.querySelector("h1 .code").innerHTML = escapeHtml(error_code);
document.querySelector("h1.mini .code").innerHTML = escapeHtml(error_code);
document.querySelector("h1 .message").innerHTML = escapeHtml(error_msg);
document.querySelector("h1.mini .message").innerHTML = escapeHtml(error_msg);
</script>
<!-- FOOTER -->
{% include footer.html %}