From ae285264c53e1a14e5e3df66cbfe3d9895532b12 Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Fri, 25 Oct 2013 16:17:35 +0530 Subject: [PATCH] Update dotNet Magazine --- recipes/dot_net.recipe | 29 +++++++++++++++-------------- 1 file changed, 15 insertions(+), 14 deletions(-) diff --git a/recipes/dot_net.recipe b/recipes/dot_net.recipe index 6b39b8c97e..33c53d4757 100644 --- a/recipes/dot_net.recipe +++ b/recipes/dot_net.recipe @@ -11,30 +11,31 @@ class dotnetMagazine (BasicNewsRecipe): no_stylesheets = True encoding = 'utf8' use_embedded_content = False + auto_cleanup = True # recursion = 1 language = 'en' remove_empty_feeds = True extra_css = ' body{font-family: Arial,Helvetica,sans-serif } img{margin-bottom: 0.4em} ' cover_url = u'http://media.netmagazine.futurecdn.net/sites/all/themes/netmag/logo.png' - remove_tags_after = dict(name='footer', id=lambda x:not x) - remove_tags_before = dict(name='header', id=lambda x:not x) + #remove_tags_after = dict(name='footer', id=lambda x:not x) + #remove_tags_before = dict(name='header', id=lambda x:not x) - remove_tags = [ - dict(name='div', attrs={'class': 'item-list'}), - dict(name='h4', attrs={'class': 'std-hdr'}), - dict(name='div', attrs={'class': 'item-list share-links'}), # removes share links - dict(name=['script', 'noscript']), - dict(name='div', attrs={'id': 'comments-form'}), # comment these out if you want the comments to show - dict(name='div', attrs={'id': re.compile('advertorial_block_($|| )')}), - dict(name='div', attrs={'id': 'right-col'}), - dict(name='div', attrs={'id': 'comments'}), # comment these out if you want the comments to show - dict(name='div', attrs={'class': 'item-list related-content'}), + #remove_tags = [ + #dict(name='div', attrs={'class': 'item-list'}), + #dict(name='h4', attrs={'class': 'std-hdr'}), + #dict(name='div', attrs={'class': 'item-list share-links'}), # removes share links + #dict(name=['script', 'noscript']), + #dict(name='div', attrs={'id': 'comments-form'}), # comment these out if you want the comments to show + #dict(name='div', attrs={'id': re.compile('advertorial_block_($|| )')}), + #dict(name='div', attrs={'id': 'right-col'}), + #dict(name='div', attrs={'id': 'comments'}), # comment these out if you want the comments to show + #dict(name='div', attrs={'class': 'item-list related-content'}), - ] + #] feeds = [ - (u'net', u'http://feeds.feedburner.com/net/topstories?format=xml') + (u'net', u'http://feeds.feedburner.com/creativebloq/') ] def skip_ad_pages(self, soup):