fixed omake teather

This commit is contained in:
Damjan Košir 2015-04-26 23:32:22 +12:00
parent 08babacd81
commit 9837a87a43

View file

@ -3,7 +3,7 @@
# Copyright (C) 2012-2014 Bastian Kleineidam # Copyright (C) 2012-2014 Bastian Kleineidam
from re import compile, escape from re import compile, escape
from ..scraper import _BasicScraper from ..scraper import _BasicScraper, _ParserScraper
from ..helpers import indirectStarter from ..helpers import indirectStarter
from ..util import tagre from ..util import tagre
@ -68,15 +68,13 @@ class OkCancel(_BasicScraper):
help = 'Index format: yyyymmdd' help = 'Index format: yyyymmdd'
class OmakeTheater(_BasicScraper): class OmakeTheater(_ParserScraper):
url = 'http://omaketheater.com/' url = 'http://omaketheater.com/comics/'
rurl = escape(url) stripUrl = url + '%s/'
stripUrl = url + 'comic/%s/'
firstStripUrl = stripUrl % '1' firstStripUrl = stripUrl % '1'
imageSearch = compile(tagre("img", "src", r'(http://media\.omaketheater\.com/4koma/[^"]+)')) css = True
prevSearch = compile(tagre("a", "href", r'(%scomic/\d+/)' % rurl, after="prev")) imageSearch = ".comicImage img"
starter = indirectStarter(url, prevSearch = ".previous a"
compile(tagre("a", "href", r'(%scomic/\d+/)' % rurl)))
help = 'Index format: number (unpadded)' help = 'Index format: number (unpadded)'