Skip to content

Instantly share code, notes, and snippets.

@ndarville
Last active March 29, 2016 02:38
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
Star You must be signed in to star a gist
Save ndarville/d46d8f530b9946c72e87 to your computer and use it in GitHub Desktop.
News Genius-blocker
<script type="text/javascript">
if (window.location.host == "genius.it") {
window.location = "https://ellacydawson.wordpress.com/2016/03/25/how-news-genius-silences-writers/";
}
</script>

Just copy-paste the code to the bottom of your <body> tag in the HTML of the pages you don’t want to be annotated.

On Tumblr, go to https://www.tumblr.com/customize/yourblogname, click “Edit HTML”, and put the code at the bottom before the </body> tag. Here is what the bottom of my HTML at https://essays.tumblr.com looks like, using the default theme:

        {block:IfGoogleAnalyticsID}
            <script>
              (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
              (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
              m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
              })(window,document,'script','//www.google-analytics.com/analytics.js','ga');
              ga('create', '{text:Google Analytics ID}', 'tumblr.com');
              ga('send', 'pageview');
            </script>
        {/block:IfGoogleAnalyticsID}
        <script type="text/javascript">
            if (window.location.host == "genius.it") {
                window.location = "https://ellacydawson.wordpress.com/2016/03/25/how-news-genius-silences-writers/";
            }
        </script>
    </body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment