@@ 1777-1794 (lines=18) @@ | ||
1774 | ||
1775 | class BigFootJustice(GenericNavigableComic): |
|
1776 | """Class to retrieve Big Foot Justice comics.""" |
|
1777 | # Also on http://tapastic.com/series/bigfoot-justice |
|
1778 | name = 'bigfoot' |
|
1779 | long_name = 'Big Foot Justice' |
|
1780 | url = 'http://bigfootjustice.com' |
|
1781 | get_first_comic_link = get_a_navi_navifirst |
|
1782 | get_navi_link = get_a_navi_comicnavnext_navinext |
|
1783 | ||
1784 | @classmethod |
|
1785 | def get_comic_info(cls, soup, link): |
|
1786 | """Get information about a particular comics.""" |
|
1787 | imgs = soup.find('div', id='comic').find_all('img') |
|
1788 | assert all(i['title'] == i['alt'] for i in imgs) |
|
1789 | title = ' '.join(i['title'] for i in imgs) |
|
1790 | return { |
|
1791 | 'img': [i['src'] for i in imgs], |
|
1792 | 'title': title, |
|
1793 | } |
|
1794 | ||
1795 | ||
1796 | class RespawnComic(GenericNavigableComic): |
|
1797 | """Class to retrieve Respawn Comic.""" |
|
@@ 2730-2746 (lines=17) @@ | ||
2727 | 'month': day.month, |
|
2728 | 'year': day.year |
|
2729 | } |
|
2730 | ||
2731 | ||
2732 | class PlanC(GenericNavigableComic): |
|
2733 | """Class to retrieve Plan C comics.""" |
|
2734 | name = 'planc' |
|
2735 | long_name = 'Plan C' |
|
2736 | url = 'http://www.plancomic.com' |
|
2737 | get_first_comic_link = get_a_navi_navifirst |
|
2738 | get_navi_link = get_a_navi_comicnavnext_navinext |
|
2739 | ||
2740 | @classmethod |
|
2741 | def get_comic_info(cls, soup, link): |
|
2742 | """Get information about a particular comics.""" |
|
2743 | title = soup.find('h2', class_='post-title').string |
|
2744 | date_str = soup.find("span", class_="post-date").string |
|
2745 | day = string_to_date(date_str, "%B %d, %Y") |
|
2746 | imgs = soup.find('div', id='comic').find_all('img') |
|
2747 | return { |
|
2748 | 'title': title, |
|
2749 | 'img': [i['src'] for i in imgs], |