mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Merge branch 'master' of https://github.com/unkn0w7n/calibre
This commit is contained in:
commit
971d346cc1
@ -146,6 +146,9 @@ class ft(BasicNewsRecipe):
|
||||
return html
|
||||
|
||||
def preprocess_html(self, soup):
|
||||
p = soup.find(**classes('o-topper__standfirst'))
|
||||
if p:
|
||||
p.name = 'p'
|
||||
for table in soup.findAll('table'):
|
||||
if len(table.find('tbody').findAll('tr')) > 20:
|
||||
table.find('tbody').decompose()
|
||||
|
@ -76,7 +76,9 @@ class MitTechnologyReview(BasicNewsRecipe):
|
||||
soup = self.index_to_soup(self.INDEX)
|
||||
issue = soup.find(attrs={'class':lambda x: x and x.startswith('magazineHero__title')})
|
||||
time = soup.find(attrs={'class': lambda x: x and x.startswith('magazineHero__date')})
|
||||
desc = soup.find(attrs={'class': lambda x: x and x.startswith('magazineHero__description')})
|
||||
self.title = 'MIT Tech Review ' + self.tag_to_string(issue)
|
||||
self.description = self.tag_to_string(desc)
|
||||
self.timefmt = ' [' + self.tag_to_string(time) + ']'
|
||||
self.log('Downloading issue: ', self.timefmt)
|
||||
|
||||
|
@ -65,7 +65,7 @@ class TheWeek(BasicNewsRecipe):
|
||||
]
|
||||
|
||||
remove_tags = [
|
||||
dict(name='aside'),
|
||||
dict(name=['aside', 'source']),
|
||||
classes(
|
||||
'blueconic-article__wrapper ad-unit van_vid_carousel tag-links'
|
||||
)
|
||||
|
@ -65,7 +65,7 @@ class TheWeek(BasicNewsRecipe):
|
||||
]
|
||||
|
||||
remove_tags = [
|
||||
dict(name='aside'),
|
||||
dict(name=['aside', 'source']),
|
||||
classes(
|
||||
'blueconic-article__wrapper ad-unit van_vid_carousel tag-links'
|
||||
)
|
||||
|
Loading…
x
Reference in New Issue
Block a user