I'm trying to make my own recipe for the sun.co.uk but I'm having a few probs
I'm using just one feed at the minute to speed up downloading while testing and I'm trying to fetch just the main article.
The custom recipe I've come up with is
Code:
class AdvancedUserRecipe1268409464(BasicNewsRecipe):
title = u'The Sun'
oldest_article = 3
max_articles_per_feed = 100
no_stylesheets = True
extra_css = '.headline {font-size: x-large;} \n .fact { padding-top: 10pt }'
keep_only_tags = [
dict(name='div', attrs={'class':'medium-centered'})
,dict(name='div', attrs={'class':'article'})
]
remove_tags = [dict(name='div', attrs={'class':'slideshow'})]
feeds = [(u'News', u'http://www.thesun.co.uk/sol/homepage/feeds/rss/article312900.ece')]
def print_version(self, url):
return url.replace('?OTC-RSS&ATTR=News', '?print=yes')
def print_version(self, url):
return url.replace('?OTC-RSS&ATTR=Royals', '?print=yes')
def print_version(self, url):
return url.replace('?OTC-RSS&ATTR=Gizmo', '?print=yes')
But this is not fetching anything.
Can anyone give me some pointers please?