@@ 1778-1795 (lines=18) @@ | ||
1775 | } |
|
1776 | ||
1777 | ||
1778 | class BigFootJustice(GenericNavigableComic): |
|
1779 | """Class to retrieve Big Foot Justice comics.""" |
|
1780 | # Also on http://tapastic.com/series/bigfoot-justice |
|
1781 | name = 'bigfoot' |
|
1782 | long_name = 'Big Foot Justice' |
|
1783 | url = 'http://bigfootjustice.com' |
|
1784 | get_first_comic_link = get_a_navi_navifirst |
|
1785 | get_navi_link = get_a_navi_comicnavnext_navinext |
|
1786 | ||
1787 | @classmethod |
|
1788 | def get_comic_info(cls, soup, link): |
|
1789 | """Get information about a particular comics.""" |
|
1790 | imgs = soup.find('div', id='comic').find_all('img') |
|
1791 | assert all(i['title'] == i['alt'] for i in imgs) |
|
1792 | title = ' '.join(i['title'] for i in imgs) |
|
1793 | return { |
|
1794 | 'img': [i['src'] for i in imgs], |
|
1795 | 'title': title, |
|
1796 | } |
|
1797 | ||
1798 | ||
@@ 2707-2723 (lines=17) @@ | ||
2704 | } |
|
2705 | ||
2706 | ||
2707 | class BuniComic(GenericNavigableComic): |
|
2708 | """Class to retrieve Buni Comics.""" |
|
2709 | name = 'buni' |
|
2710 | long_name = 'BuniComics' |
|
2711 | url = 'http://www.bunicomic.com' |
|
2712 | get_first_comic_link = get_a_comicnavbase_comicnavfirst |
|
2713 | get_navi_link = get_link_rel_next |
|
2714 | ||
2715 | @classmethod |
|
2716 | def get_comic_info(cls, soup, link): |
|
2717 | """Get information about a particular comics.""" |
|
2718 | imgs = soup.find('div', id='comic').find_all('img') |
|
2719 | assert all(i['alt'] == i['title'] for i in imgs) |
|
2720 | assert len(imgs) == 1 |
|
2721 | return { |
|
2722 | 'img': [i['src'] for i in imgs], |
|
2723 | 'title': imgs[0]['title'], |
|
2724 | } |
|
2725 | ||
2726 |