-
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.
Add functionality to redirect from an internal link to an external URL.
- Loading branch information
1 parent
1618fe0
commit b47fd54
Showing
2 changed files
with
22 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
from,to |
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,21 @@ | ||
--- | ||
pagination: | ||
data: redirect_to | ||
size: 1 | ||
alias: redirect | ||
addAllPagesToCollections: false | ||
permalink: '{{ redirect.from }}' | ||
eleventyExcludeFromCollections: true | ||
layout: null | ||
--- | ||
<!DOCTYPE html> | ||
<html lang='en' style='background:black;width:100%;height:100%'> | ||
<meta charset='utf-8'> | ||
<title>Redirect to {{ redirect.to }}</title> | ||
<link rel='canonical' href='{{ redirect.to }}'> | ||
<script>location = '{{ redirect.to }}';</script> | ||
<meta http-equiv='refresh' content='0; url={{ redirect.to }}'> | ||
<meta name='robots' content='noindex'> | ||
<h1 style='color:white;text-align:center'>Redirecting to {{ redirect.to }}</h1> | ||
<p><a style='color:mediumspringgreen;text-align:center' href='{{ redirect.to }}'>Click here if you are not being redirected.</a></p> | ||
</html> |