mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Improved recipe for Newsweek
This commit is contained in:
parent
4b413dfef3
commit
093404e208
@ -33,19 +33,21 @@ class Newsweek(BasicNewsRecipe):
|
|||||||
language = 'en'
|
language = 'en'
|
||||||
|
|
||||||
remove_tags = [
|
remove_tags = [
|
||||||
{'class':['fwArticle noHr','fwArticle','subinfo','hdlBulletItem','head-content','navbar','link', 'ad', 'sponsorLinksArticle', 'mm-content',
|
{'class':['fwArticle noHr','fwArticle','hdlBulletItem','head-content','navbar','link', 'ad', 'sponsorLinksArticle', 'mm-content',
|
||||||
'inline-social-links-wrapper', 'email-article','ToolBox',
|
'inline-social-links-wrapper', 'email-article','ToolBox',
|
||||||
|
'inline-promo-link', 'sponsorship',
|
||||||
'inlineComponentRight',
|
'inlineComponentRight',
|
||||||
'comments-and-social-links-wrapper', 'EmailArticleBlock']},
|
'comments-and-social-links-wrapper', 'EmailArticleBlock']},
|
||||||
{'id' : ['footer', 'ticker-data', 'topTenVertical',
|
{'id' : ['footer', 'ticker-data', 'topTenVertical',
|
||||||
'digg-top-five', 'mesothorax', 'nw-comments',
|
'digg-top-five', 'mesothorax', 'nw-comments', 'my-take-landing',
|
||||||
'ToolBox', 'EmailMain']},
|
'ToolBox', 'EmailMain']},
|
||||||
{'class': re.compile('related-cloud')},
|
{'class': re.compile('related-cloud')},
|
||||||
dict(name='li', attrs={'id':['slug_bigbox']})
|
dict(name='li', attrs={'id':['slug_bigbox']})
|
||||||
]
|
]
|
||||||
|
|
||||||
|
|
||||||
keep_only_tags = [{'class':['article HorizontalHeader', 'articlecontent','photoBox']}, ]
|
keep_only_tags = [{'class':['article HorizontalHeader',
|
||||||
|
'articlecontent','photoBox', 'article columnist first']}, ]
|
||||||
recursions = 1
|
recursions = 1
|
||||||
match_regexps = [r'http://www.newsweek.com/id/\S+/page/\d+']
|
match_regexps = [r'http://www.newsweek.com/id/\S+/page/\d+']
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user