|
@@ 1725-1742 (lines=18) @@
|
| 1722 |
|
'author': author, |
| 1723 |
|
} |
| 1724 |
|
|
| 1725 |
|
|
| 1726 |
|
class BigFootJustice(GenericNavigableComic): |
| 1727 |
|
"""Class to retrieve Big Foot Justice comics.""" |
| 1728 |
|
# Also on http://tapastic.com/series/bigfoot-justice |
| 1729 |
|
name = 'bigfoot' |
| 1730 |
|
long_name = 'Big Foot Justice' |
| 1731 |
|
url = 'http://bigfootjustice.com' |
| 1732 |
|
get_first_comic_link = get_a_navi_navifirst |
| 1733 |
|
get_navi_link = get_a_navi_comicnavnext_navinext |
| 1734 |
|
|
| 1735 |
|
@classmethod |
| 1736 |
|
def get_comic_info(cls, soup, link): |
| 1737 |
|
"""Get information about a particular comics.""" |
| 1738 |
|
imgs = soup.find('div', id='comic').find_all('img') |
| 1739 |
|
assert all(i['title'] == i['alt'] for i in imgs) |
| 1740 |
|
title = ' '.join(i['title'] for i in imgs) |
| 1741 |
|
return { |
| 1742 |
|
'img': [i['src'] for i in imgs], |
| 1743 |
|
'title': title, |
| 1744 |
|
} |
| 1745 |
|
|
|
@@ 2600-2616 (lines=17) @@
|
| 2597 |
|
'day': day.day, |
| 2598 |
|
} |
| 2599 |
|
|
| 2600 |
|
|
| 2601 |
|
class BuniComic(GenericNavigableComic): |
| 2602 |
|
"""Class to retrieve Buni Comics.""" |
| 2603 |
|
name = 'buni' |
| 2604 |
|
long_name = 'BuniComics' |
| 2605 |
|
url = 'http://www.bunicomic.com' |
| 2606 |
|
get_first_comic_link = get_a_comicnavbase_comicnavfirst |
| 2607 |
|
get_navi_link = get_link_rel_next |
| 2608 |
|
|
| 2609 |
|
@classmethod |
| 2610 |
|
def get_comic_info(cls, soup, link): |
| 2611 |
|
"""Get information about a particular comics.""" |
| 2612 |
|
imgs = soup.find('div', id='comic').find_all('img') |
| 2613 |
|
assert all(i['alt'] == i['title'] for i in imgs) |
| 2614 |
|
assert len(imgs) == 1 |
| 2615 |
|
return { |
| 2616 |
|
'img': [i['src'] for i in imgs], |
| 2617 |
|
'title': imgs[0]['title'], |
| 2618 |
|
} |
| 2619 |
|
|