# -*- coding: iso-8859-1 -*- # Copyright (C) 2004-2005 Tristan Seligmann and Jonathan Jacobs # Copyright (C) 2012 Bastian Kleineidam """ The Universal comics only have some samples, but those samples are always the newest ones. """ import datetime from re import compile, escape from ..scraper import make_scraper from ..util import tagre, asciify, getPageContent def parse_strdate(strdate): """Parse date string. XXX this is locale dependant but it should not be.""" return datetime.datetime.strptime(strdate, "%A, %B %d, %Y") def add(name, category): shortname = name.replace(' ', '').lower() latestUrl = 'http://www.universaluclick.com/comics/%s/%s' % (category, shortname) classname = 'UClick_%s' % asciify(name) @classmethod def namer(cls, imageUrl, pageUrl): """Parse publish date from page content which looks like: