mlookdlurl

enter something useful

スクリプトをインストールするには、Tampermonkey, GreasemonkeyViolentmonkey のような拡張機能のインストールが必要です。

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

スクリプトをインストールするには、TampermonkeyViolentmonkey のような拡張機能のインストールが必要です。

スクリプトをインストールするには、TampermonkeyUserscripts のような拡張機能のインストールが必要です。

このスクリプトをインストールするには、Tampermonkeyなどの拡張機能をインストールする必要があります。

このスクリプトをインストールするには、ユーザースクリプト管理ツールの拡張機能をインストールする必要があります。

(ユーザースクリプト管理ツールは設定済みなのでインストール!)

このスタイルをインストールするには、Stylusなどの拡張機能をインストールする必要があります。

このスタイルをインストールするには、Stylus などの拡張機能をインストールする必要があります。

このスタイルをインストールするには、Stylus tなどの拡張機能をインストールする必要があります。

このスタイルをインストールするには、ユーザースタイル管理用の拡張機能をインストールする必要があります。

このスタイルをインストールするには、ユーザースタイル管理用の拡張機能をインストールする必要があります。

このスタイルをインストールするには、ユーザースタイル管理用の拡張機能をインストールする必要があります。

(ユーザースタイル管理ツールは設定済みなのでインストール!)

このスクリプトの質問や評価の投稿はこちら通報はこちらへお寄せください
// ==UserScript==
// @name       mlookdlurl
// @namespace  http://userscripts.org/scripts/show/180403
// @version    0.3
// @description  enter something useful
// @match      http://*.mlook.mobi/*
// @exclude	   http://*.mlook.mobi/forum/*
// ==/UserScript==


function dlurl() {
var url = document.URL;
var reg = /http:\/\/(www\.|)mlook\.mobi\/book\/info\/(\d*)/;
 if ((url.search(/info/g) != -1) && (url.search(/doubanbook/g) == -1)) {
        
        self.location.href = reg.exec(url)[2]+'?rel=doubanbook2mlook';
    }
}
$(document).ready(function() {
    dlurl();
    var arr = $('a');
    
	for (var i = 0;i < arr.length;i++) {
        href = arr[i].href;
    	if (href.search(/info/g)!=-1) {
        	$(arr[i]).attr("href",href+"?rel=doubanbook2mlook");
    	}
	};
    
})