Last active
December 17, 2022 15:56
-
-
Save Enichan/4008d39a0d2f402b302a901534506f28 to your computer and use it in GitHub Desktop.
Mastodon redirect HTML template
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
<!DOCTYPE html> | |
<html lang="en"> | |
<!-- | |
Just search and replace the following tags: | |
{name} replace with your printed name (ex 'Elon Musk') | |
{image-url} replace with a 4:3 image, presumably your avatar | |
{twitter-username} replace with your twitter username (ex 'elonmusk') | |
{profile-url} replace with your mastodon profile url (ex 'https://mastodon.social/@Gargron') | |
Then place resulting html file on a web server you own and link to that instead | |
IMPORTANT: if you're using this and you still want to be found by fedifinder, movetodon, or debirdify, you | |
should put your @user@domain mastodon handle in your bio/location/pinned tweet alongside the redirecting url | |
--> | |
<head> | |
<meta name="description" content="Redirects to {name}'s mastodon account to circumvent censorship by Elon Musk" /> | |
<meta charset="utf-8"> | |
<title>Redirects to {name}'s mastodon account to circumvent censorship by Elon Musk</title> | |
<meta name="viewport" content="width=device-width, initial-scale=1"> | |
<meta name="twitter:card" content="summary" /> | |
<meta name="twitter:title" content="Redirects to {name}'s mastodon account to circumvent censorship by Elon Musk" /> | |
<meta name="twitter:image" content="{image-url}" /> | |
<meta name="twitter:site" content="@{twitter-username}" /> | |
</head> | |
<body> | |
You will be redirected to <a href="{profile-url}">{profile-url}</a> in a couple of seconds. Please click <a href="{profile-url}">the link</a> if you are not redirected or have javascript disabled. | |
<script> | |
function fredirect() { | |
window.location.href = "{profile-url}"; | |
} | |
timeout = setTimeout(fredirect, 3000); | |
</script> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
That would probably work too. I put it on a timer just in case they're doing some rudimentary redirect detection that happens (near) instantly. Figured it can't hurt and would probably be slightly more robust.