View Single Post
Old 11-18-2010, 10:37 AM   #5
Nexus
Member
Nexus began at the beginning.
 
Posts: 11
Karma: 10
Join Date: Nov 2010
Location: France
Device: PRS-600
Ok so here's a nicer recipe for THN:

Spoiler:
Code:
class AdvancedUserRecipe1289990851(BasicNewsRecipe):
    title          = u'THE HOCKEY NEWS'
    oldest_article = 7
    max_articles_per_feed = 25
    no_stylesheets = True
    remove_tags = [dict(name='div', attrs={'class':'article_info'}),
                          dict(name='div', attrs={'class':'photo_details'}),
                          dict(name='div', attrs={'class':'tool_menu'}),
	                  dict(name='div', attrs={'id':'comments_container'}),
                          dict(name='div', attrs={'id':'wrapper'})]
    keep_only_tags = [dict(name='h1', attrs={'class':['headline']}),
		                dict(name='div', attrs={'class':['box_container']})]
	
    feeds          = [(u'THN', u'http://www.thehockeynews.com/rss/all_categories.xml')]



And I got the RDS one too.

Spoiler:
Code:
class AdvancedUserRecipe1290013720(BasicNewsRecipe):
    title          = u'RDS'
    oldest_article = 7
    max_articles_per_feed = 25
    no_stylesheets = True
    remove_tags = [dict(name='div', attrs={'id':'rdsWrap'}),
		            dict(name='table', attrs={'id':'aVoir'}),
		            dict(name='div', attrs={'id':'imageChronique'})]
    keep_only_tags = [dict(name='div', attrs={'id':['enteteChronique']}),
		                dict(name='div', attrs={'id':['contenuChronique']})]
		       

    feeds          = [(u'RDS', u'http://www.rds.ca/hockey/fildepresse_rds.xml')]


TSN remains a mystery...
Nexus is offline   Reply With Quote