dm5.com image list

Lists all images in a chapter/volume

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴Greasemonkey 油猴子Violentmonkey 暴力猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴Violentmonkey 暴力猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴Userscripts ,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展后才能安装此脚本。

(我已经安装了用户脚本管理器,让我安装!)

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

(我已经安装了用户样式管理器,让我安装!)

// ==UserScript==
// @name               dm5.com image list
// @description        Lists all images in a chapter/volume
// @name:zh-TW         DM5 漫畫列表
// @description:zh-TW  列出章節內所有圖片
// @version            1.1.2
// @include            /^https\:\/\/.*?\.dm5\.com\//
// @author             willy_sunny
// @license            GPL version 2 or any later version; http://www.gnu.org/licenses/gpl-2.0.txt
// @namespace https://greasyfork.org/users/9968
// ==/UserScript==
//
// ************************
// Own Variable Declaration
// ************************
// imgList: the output result
// 

var imgList="";
var nextChap = "";
try { 
	nextChap = $('.view-btn-next')[0].href;
} catch (e) { 
	nextChap ="#' onClick='alert(\"End of chapter\")";
}
function lp(p, list, count, callback) {
	$.ajax({
		url: 'chapterfun.ashx', 
		data: { 
			cid: DM5_CID, 
			page: p, 
			key: $("#dm5_key").val(), 
			language: 1, 
			gtk: 6, 
			_cid: DM5_CID, 
			_mid: DM5_MID, 
			_dt: DM5_VIEWSIGN_DT, 
			_sign: DM5_VIEWSIGN 
		}, 
		type: 'GET', 
		success: function (data) {
			eval(data);
			if(p>count) {
				callback(list);
			} else {
				document.body.innerHTML = "Loading Page " + p + "/" + count;
				lp(p+1, list+'<img src="' + d[0] + '"><br>', count, callback);
			}
		}
	})
}
imgList=lp(1,"",DM5_IMAGE_COUNT, function(data) {
	document.body.innerHTML = "<center>" + data + "<br><br><a href='" + nextChap + "'>Next &gt;&gt;</a></center>";
});
document.body.style.overflow = 'scroll';