Skip to content

Commit 7be2897

Browse files
authored
Create 404.html with redirects (#1889)
* Create 404.html with redirects * Create index.html
1 parent 3a1e332 commit 7be2897

File tree

2 files changed

+59
-0
lines changed

2 files changed

+59
-0
lines changed

404.html

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
<!doctype html>
2+
<html>
3+
<head>
4+
<meta name="viewport" content="width=device-width, initial-scale=1" />
5+
<meta charset="utf-8"/>
6+
<title>MapKnitter | static archive</title>
7+
8+
<link rel="stylesheet" href="https://jywarren.github.io/markdown-pages/node_modules/spectre-markdown.css/dist/markdown.css">
9+
<link rel="stylesheet"
10+
href="https://fonts.googleapis.com/css2?family=Lora">
11+
<link rel="stylesheet" href="https://jywarren.github.io/markdown-pages-template/style.css">
12+
</head>
13+
<body>
14+
<header>
15+
<a href="#">MapKnitter</a>
16+
</header>
17+
<div class="md-pages markdown-css responsive"></div>
18+
<!--
19+
https://mapknitter.org/map/tidwell-park
20+
should become:
21+
https://publiclab.github.io/Leaflet.DistortableImage/examples/archive?json=https://archive.org/download/mapknitter-wayback/tidwell-park.json
22+
and same with https://mapknitter.org/embed/tidwell-park
23+
-->
24+
<script>
25+
if (window.location == "https://mapknitter.org/") {
26+
window.location = "https://publiclab.github.io/Leaflet.DistortableImage/examples/archive/";
27+
} else if (window.location.split('/')[4] == "embed") {
28+
var path = "https://publiclab.github.io/Leaflet.DistortableImage/examples/archive?json=https://archive.org/download/mapknitter-wayback/" + document.location.href.split('.org/embed/')[1];
29+
window.location.replace("https://publiclab.github.io/Leaflet.DistortableImage/" + path);
30+
} else {
31+
var path = "https://publiclab.github.io/Leaflet.DistortableImage/examples/archive?json=https://archive.org/download/mapknitter-wayback/" + document.location.href.split('.org/map/')[1];
32+
window.location.replace("https://publiclab.github.io/Leaflet.DistortableImage/" + path);
33+
}
34+
</script>
35+
</body>
36+
</html>

index.html

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
<!doctype html>
2+
<html>
3+
<head>
4+
<meta name="viewport" content="width=device-width, initial-scale=1" />
5+
<meta charset="utf-8"/>
6+
<title>MapKnitter | static archive</title>
7+
8+
<link rel="stylesheet" href="https://jywarren.github.io/markdown-pages/node_modules/spectre-markdown.css/dist/markdown.css">
9+
<link rel="stylesheet"
10+
href="https://fonts.googleapis.com/css2?family=Lora">
11+
<link rel="stylesheet" href="https://jywarren.github.io/markdown-pages-template/style.css">
12+
</head>
13+
<body>
14+
<header>
15+
<a href="#">MapKnitter</a>
16+
</header>
17+
<div class="md-pages markdown-css responsive"></div>
18+
Redirecting to <a href="https://publiclab.github.io/Leaflet.DistortableImage/examples/archive/">https://publiclab.github.io/Leaflet.DistortableImage/examples/archive/</a> ...
19+
<script>
20+
window.location = "https://publiclab.github.io/Leaflet.DistortableImage/examples/archive/";
21+
</script>
22+
</body>
23+
</html>

0 commit comments

Comments
 (0)