mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Project Syndicate update
This commit is contained in:
parent
600760c170
commit
dc1e4de91f
@ -28,12 +28,12 @@ class outlook(BasicNewsRecipe):
|
|||||||
remove_tags = [
|
remove_tags = [
|
||||||
classes(
|
classes(
|
||||||
'social_sharing_article left_trending left-sticky __tag_links next_prev_stories '
|
'social_sharing_article left_trending left-sticky __tag_links next_prev_stories '
|
||||||
'downarrow uparrow more_from_author_links next prev __related_stories_thumbs'
|
'downarrow uparrow more_from_author_links next prev __related_stories_thumbs home_ad_title'
|
||||||
)
|
)
|
||||||
]
|
]
|
||||||
|
|
||||||
def get_browser(self):
|
def get_browser(self):
|
||||||
return BasicNewsRecipe.get_browser(self, user_agent='common_words/based')
|
return BasicNewsRecipe.get_browser(self, user_agent='common_words/based', verify_ssl_certificates=False)
|
||||||
|
|
||||||
def parse_index(self):
|
def parse_index(self):
|
||||||
soup = self.index_to_soup('https://www.outlookindia.com/magazine')
|
soup = self.index_to_soup('https://www.outlookindia.com/magazine')
|
||||||
|
@ -10,7 +10,8 @@ class projectsynd(BasicNewsRecipe):
|
|||||||
'Featuring exclusive contributions by prominent political leaders, policymakers, scholars, business '
|
'Featuring exclusive contributions by prominent political leaders, policymakers, scholars, business '
|
||||||
'leaders, and civic activists from around the world, we provide news media and their readers with cutting-edge '
|
'leaders, and civic activists from around the world, we provide news media and their readers with cutting-edge '
|
||||||
'analysis and insight, regardless of ability to pay. Our membership includes over 500 media outlets – more '
|
'analysis and insight, regardless of ability to pay. Our membership includes over 500 media outlets – more '
|
||||||
'than half of which receive our commentaries for free or at subsidized rates – in 156 countries.'
|
'than half of which receive our commentaries for free or at subsidized rates – in 156 countries. '
|
||||||
|
'Download Weekly.'
|
||||||
)
|
)
|
||||||
language = 'en'
|
language = 'en'
|
||||||
no_stylesheets = True
|
no_stylesheets = True
|
||||||
@ -35,17 +36,20 @@ class projectsynd(BasicNewsRecipe):
|
|||||||
[itemprop^="associatedMedia"]{ font-size:small; text-align:center; }
|
[itemprop^="associatedMedia"]{ font-size:small; text-align:center; }
|
||||||
[itemprop="author"], time { font-size:small; }
|
[itemprop="author"], time { font-size:small; }
|
||||||
.sub, em { font-style:italic; color:#202020; }
|
.sub, em { font-style:italic; color:#202020; }
|
||||||
|
[data-page-area="article-bottom"] { font-size:small; color:#202020; }
|
||||||
'''
|
'''
|
||||||
|
|
||||||
keep_only_tags = [
|
keep_only_tags = [
|
||||||
dict(attrs={'itemprop':lambda x: x and 'associatedMedia' in x.split()}),
|
dict(attrs={'itemprop':lambda x: x and 'associatedMedia' in x.split()}),
|
||||||
dict(attrs={'itemprop':['headline', 'datePublished', 'author', 'abstract', 'articleBody']}),
|
dict(attrs={'itemprop':['headline', 'datePublished', 'author', 'abstract', 'articleBody']}),
|
||||||
|
dict(name = 'aside', attrs={'data-page-area':'article-bottom'})
|
||||||
]
|
]
|
||||||
|
|
||||||
remove_tags = [
|
remove_tags = [
|
||||||
dict(name=['button', 'svg']),
|
dict(name=['button', 'svg']),
|
||||||
dict(attrs={'data-message-area':True}),
|
dict(attrs={'data-message-area':True}),
|
||||||
dict(attrs={'id':['editorspicks', 'movie_player']}),
|
dict(attrs={'id':['editorspicks', 'movie_player']}),
|
||||||
|
dict(name='aside', attrs={'id':lambda x: x and x.startswith('comments-')})
|
||||||
]
|
]
|
||||||
|
|
||||||
feeds = [
|
feeds = [
|
||||||
|
Loading…
x
Reference in New Issue
Block a user