mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-08 10:44:09 -04:00
Update Outlook India
This commit is contained in:
parent
ab8a91dc55
commit
a2823eceed
@ -14,13 +14,13 @@ class outlook(BasicNewsRecipe):
|
|||||||
ignore_duplicate_articles = {'url'}
|
ignore_duplicate_articles = {'url'}
|
||||||
|
|
||||||
def parse_index(self):
|
def parse_index(self):
|
||||||
soup = self.index_to_soup('https://www.outlookindia.com/magazine/archive')
|
soup = self.index_to_soup('https://www.outlookindia.com/')
|
||||||
issue = soup.find(**classes('issue_listing'))
|
a = soup.find('a', href=lambda x: x and x.startswith('/magazine/issue/'))
|
||||||
a = issue.find('a', href=lambda x: x and x.startswith('/magazine/issue/'))
|
|
||||||
url = a['href']
|
url = a['href']
|
||||||
self.log('Downloading issue:', url)
|
self.log('Downloading issue:', url)
|
||||||
self.cover_url = a.find('img', attrs={'src': True})['src']
|
|
||||||
soup = self.index_to_soup('https://www.outlookindia.com' + url)
|
soup = self.index_to_soup('https://www.outlookindia.com' + url)
|
||||||
|
cover = soup.find(**classes('listingPage_lead_story'))
|
||||||
|
self.cover_url = cover.find('img', attrs={'src': True})['src']
|
||||||
ans = []
|
ans = []
|
||||||
|
|
||||||
for h3 in soup.findAll(['h3', 'h4'],
|
for h3 in soup.findAll(['h3', 'h4'],
|
||||||
|
Loading…
x
Reference in New Issue
Block a user