-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
cdcb92f
commit ddcc5de
Showing
3 changed files
with
40 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
<!DOCTYPE html> | ||
<html> | ||
<head> | ||
<meta charset="utf-8"> | ||
<title>Page Not Found</title> | ||
<script> | ||
// Single Page Apps for GitHub Pages | ||
// https://github.com/rafgraph/spa-github-pages | ||
const pathSegmentsToKeep = 0; // Site is published at the root of custom domain soen357.ngrenier.com | ||
|
||
const l = window.location; | ||
// Save the URL path (minus the repo part) | ||
const redirectPath = l.pathname.split('/').slice(pathSegmentsToKeep + 1).join('/') + | ||
(l.search ? l.search : '') + (l.hash ? l.hash : ''); | ||
|
||
// Redirect to the index.html with the path as a query parameter | ||
sessionStorage.setItem('redirect', redirectPath); | ||
l.replace( | ||
l.protocol + '//' + l.hostname + (l.port ? ':' + l.port : '') + | ||
l.pathname.split('/').slice(0, pathSegmentsToKeep + 1).join('/') + '/?/' + | ||
redirectPath | ||
); | ||
</script> | ||
</head> | ||
<body> | ||
Redirecting... | ||
</body> | ||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters