mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-08-07 09:01:38 -04:00
Update Howto Geek
This commit is contained in:
parent
77bd4f4544
commit
8452127896
@ -13,14 +13,22 @@ class AdvancedUserRecipe1282101454(BasicNewsRecipe):
|
|||||||
linearize_tables = True
|
linearize_tables = True
|
||||||
no_stylesheets = True
|
no_stylesheets = True
|
||||||
remove_javascript = True
|
remove_javascript = True
|
||||||
masthead_url = 'http://blog.stackoverflow.com/wp-content/uploads/how-to-geek-logo.png'
|
|
||||||
|
|
||||||
remove_tags = [dict(name='a', attrs={'target': ['_blank']}),
|
keep_only_tags = [
|
||||||
dict(name='table', attrs={'id': ['articleTable']}),
|
dict(id='main')
|
||||||
dict(name='div', attrs={'class': ['feedflare']}),
|
]
|
||||||
]
|
remove_tags = [
|
||||||
|
dict(name='a', attrs={'target': ['_blank']}),
|
||||||
|
dict(name='table', attrs={'id': ['articleTable']}),
|
||||||
|
dict(name='div', attrs={'class': ['feedflare', 'article-share-widgets']}),
|
||||||
|
]
|
||||||
|
|
||||||
feeds = [
|
feeds = [
|
||||||
('Tips', 'http://feeds.howtogeek.com/howtogeek')
|
('Tips', 'http://feeds.howtogeek.com/howtogeek')
|
||||||
|
|
||||||
]
|
]
|
||||||
|
|
||||||
|
def preprocess_html(self, soup, *a):
|
||||||
|
for img in soup.findAll('img', attrs={'data-pagespeed-lazy-src': True}):
|
||||||
|
img['src'] = img['data-pagespeed-lazy-src']
|
||||||
|
return soup
|
||||||
|
Loading…
x
Reference in New Issue
Block a user