Fjords begone

Redirects fjorded e-hentai galleries to their sadpanda version.

Fra 04.06.2014. Se den seneste versjonen.

You will need to install an extension such as Tampermonkey, Greasemonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey or Userscripts to install this script.

You will need to install an extension such as Tampermonkey to install this script.

You will need to install a user script manager extension to install this script.

(I already have a user script manager, let me install it!)

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

(I already have a user style manager, let me install it!)

// ==UserScript==
// @name           Fjords begone
// @namespace      Mexiguy
// @author         Mexiguy
// @version        1.0
// @description    Redirects fjorded e-hentai galleries to their sadpanda version.
// @include        http://g.e-hentai.org/*
// @grant          none
// @run-at         document-start
// ==/UserScript==

//Get the page title and URL of the gallery
var title = document.title;
var url = document.location.toString().toLowerCase();

//Check if it's fjorded
if (title.search("Gallery Not Available") != -1)
{
    document.title = "Redirecting..."
    
    //Change the URL to the sadpanda one and redirect.
    url = url.replace("g.e-hentai", "exhentai");
    document.location = url;
}