2012-06-20 20:41:04 +00:00
|
|
|
# -*- coding: iso-8859-1 -*-
|
|
|
|
# Copyright (C) 2004-2005 Tristan Seligmann and Jonathan Jacobs
|
2013-02-05 18:51:46 +00:00
|
|
|
# Copyright (C) 2012-2013 Bastian Kleineidam
|
2012-06-20 19:58:13 +00:00
|
|
|
|
2012-11-21 20:57:26 +00:00
|
|
|
from re import compile
|
2012-10-11 10:03:12 +00:00
|
|
|
from ..scraper import _BasicScraper
|
|
|
|
from ..helpers import indirectStarter
|
2012-11-21 20:57:26 +00:00
|
|
|
from ..util import tagre
|
2012-06-20 19:58:13 +00:00
|
|
|
|
|
|
|
|
|
|
|
class OctopusPie(_BasicScraper):
|
2013-02-04 20:00:26 +00:00
|
|
|
url = 'http://www.octopuspie.com/'
|
|
|
|
starter = indirectStarter(url,
|
2012-11-21 20:57:26 +00:00
|
|
|
compile(tagre("a", "href", r'(http://www\.octopuspie\.com/[^"]+)') +
|
|
|
|
tagre("img", "src", r'http://www\.octopuspie\.com/junk/latest\.png')))
|
2013-02-04 20:00:26 +00:00
|
|
|
stripUrl = url + '%s'
|
2012-11-21 20:57:26 +00:00
|
|
|
imageSearch = compile(tagre("img", "src", r'(http://www\.octopuspie\.com/strippy/[^"]+)'))
|
|
|
|
prevSearch = compile(tagre("a", "href", r'(http://www\.octopuspie\.com/[^"]+)', after="prev"))
|
2012-06-20 19:58:13 +00:00
|
|
|
help = 'Index format: yyyy-mm-dd/nnn-strip-name'
|
|
|
|
|
|
|
|
|
|
|
|
class OddFish(_BasicScraper):
|
2013-02-04 20:00:26 +00:00
|
|
|
url = 'http://www.odd-fish.net/'
|
|
|
|
stripUrl = url + '%s/'
|
2012-11-21 20:57:26 +00:00
|
|
|
imageSearch = compile(tagre("img", "src", r'(http://www\.odd-fish\.net/comics/[^"]+)'))
|
|
|
|
prevSearch = compile(tagre("a", "href", r'(http://www\.odd-fish\.net/[^"]+)', after="navi-prev"))
|
|
|
|
help = 'Index format: stripname'
|
2012-06-20 19:58:13 +00:00
|
|
|
|
|
|
|
|
2013-03-06 19:21:10 +00:00
|
|
|
class Oglaf(_BasicScraper):
|
|
|
|
url = 'http://oglaf.com/'
|
|
|
|
stripUrl = url + '%s/'
|
|
|
|
imageSearch = compile(tagre("img", "src", r'(/media/comic/[^"]+)', before="strip"))
|
|
|
|
prevSearch = compile(tagre("a", "href", r'([^"]+)') + tagre("div", "id", "pvs"))
|
|
|
|
help = 'Index format: stripname/nn'
|
|
|
|
|
|
|
|
|
|
|
|
class OkCancel(_BasicScraper):
|
|
|
|
url = 'http://okcancel.com/'
|
|
|
|
stripUrl = url + 'comic/%s.html'
|
|
|
|
imageSearch = compile(tagre("img", "src", r'(http://okcancel\.com/strips/okcancel\d{8}\.gif)'))
|
|
|
|
prevSearch = compile(tagre("div", "class", "previous") + tagre("a", "href", r'(http://okcancel\.com/comic/\d{1,4}\.html)'))
|
|
|
|
starter = indirectStarter(url, prevSearch)
|
|
|
|
help = 'Index format: yyyymmdd'
|
|
|
|
|
|
|
|
|
2013-02-06 21:27:40 +00:00
|
|
|
class OmakeTheater(_BasicScraper):
|
|
|
|
url = 'http://omaketheater.com/'
|
|
|
|
stripUrl = url + 'comic/%s'
|
|
|
|
imageSearch = compile(tagre("img", "src", r'(http://media\.omaketheater\.com/4koma/[^"]+)'))
|
|
|
|
prevSearch = compile(tagre("a", "href", r'(http://omaketheater\.com/comic/\d+/)', after="prev"))
|
|
|
|
starter = indirectStarter(url,
|
|
|
|
compile(tagre("a", "href", r'(http://omaketheater\.com/comic/\d+/)')))
|
|
|
|
help = 'Index format: number (unpadded)'
|
|
|
|
|
|
|
|
|
2012-06-20 19:58:13 +00:00
|
|
|
class OnTheEdge(_BasicScraper):
|
2013-02-04 20:00:26 +00:00
|
|
|
url = 'http://ontheedgecomics.com/'
|
2012-12-04 06:02:40 +00:00
|
|
|
stripUrl = 'http://ontheedgecomics.com/comic/%s'
|
2012-06-20 19:58:13 +00:00
|
|
|
imageSearch = compile(r'<img src="(http://ontheedgecomics.com/comics/.+?)"')
|
|
|
|
prevSearch = compile(r'<a href="([^"]+)" rel="prev">')
|
|
|
|
help = 'Index format: nnn (unpadded)'
|
|
|
|
|
|
|
|
|
|
|
|
class OneQuestion(_BasicScraper):
|
2013-03-07 17:22:24 +00:00
|
|
|
url = 'http://onequestioncomic.com/'
|
2013-02-04 20:00:26 +00:00
|
|
|
stripUrl = url + 'comic.php?strip_id=%s'
|
2013-02-22 19:23:47 +00:00
|
|
|
imageSearch = compile(tagre("img", "src", r'((?:\.\./)?istrip_files/strips/\d+\.jpg)'))
|
2012-11-21 20:57:26 +00:00
|
|
|
prevSearch = compile(tagre("a", "href", r'(comic\.php\?strip_id=\d+)') + tagre("img", "src", r'img/arrow_prev\.jpg'))
|
2012-06-20 19:58:13 +00:00
|
|
|
help = 'Index format: n (unpadded)'
|
|
|
|
|
|
|
|
|
2013-03-12 20:23:26 +00:00
|
|
|
class OrnerBoy(_BasicScraper):
|
|
|
|
url = 'http://www.orneryboy.com/'
|
|
|
|
stripUrl = url + 'index.php?comicID=%s'
|
|
|
|
firstStripUrl = stripUrl % '1'
|
|
|
|
imageSearch = compile(tagre("img", "src", r'(comics/\d+\.[^"]+)'))
|
|
|
|
prevSearch = compile(tagre("a", "href", r'(http://www\.orneryboy\.com/index\.php\?comicID=\d+)') +
|
|
|
|
tagre("img", "src", r'images/prev_a\.gif'))
|
|
|
|
help = 'Index format: number'
|
|
|
|
|
|
|
|
|
2012-06-20 19:58:13 +00:00
|
|
|
class OurHomePlanet(_BasicScraper):
|
2013-02-04 20:00:26 +00:00
|
|
|
url = 'http://gdk.gd-kun.net/'
|
|
|
|
stripUrl = url + '%s.html'
|
2012-06-20 19:58:13 +00:00
|
|
|
imageSearch = compile(r'<img src="(pages/comic.+?)"')
|
|
|
|
prevSearch = compile(r'coords="50,18,95,65".+?href="(.+?\.html)".+?alt=')
|
|
|
|
help = 'Index format: n (unpadded)'
|
|
|
|
|
|
|
|
|
|
|
|
class OverCompensating(_BasicScraper):
|
2013-02-04 20:00:26 +00:00
|
|
|
url = 'http://www.overcompensating.com/'
|
|
|
|
stripUrl = url + 'posts/%s.html'
|
2012-06-20 19:58:13 +00:00
|
|
|
imageSearch = compile(r'<img src="(/comics/.+?)"')
|
|
|
|
prevSearch = compile(r'"><a href="(.+?)"[^>]+?> \<\- </a>')
|
|
|
|
help = 'Index format: yyyymmdd'
|