diff --git a/src/calibre/web/feeds/recipes/__init__.py b/src/calibre/web/feeds/recipes/__init__.py index a2dbcd7d24..191bf905ca 100644 --- a/src/calibre/web/feeds/recipes/__init__.py +++ b/src/calibre/web/feeds/recipes/__init__.py @@ -39,6 +39,7 @@ recipe_modules = ['recipe_' + r for r in ( 'nacional_cro', '24sata', 'dnevni_avaz', 'glas_srpske', '24sata_rs', 'krstarica', 'krstarica_en', 'tanjug', 'laprensa_ni', 'azstarnet', 'corriere_della_sera_it', 'corriere_della_sera_en', 'msdnmag_en', + 'moneynews', )] import re, imp, inspect, time, os diff --git a/src/calibre/web/feeds/recipes/recipe_moneynews.py b/src/calibre/web/feeds/recipes/recipe_moneynews.py new file mode 100644 index 0000000000..96656e490d --- /dev/null +++ b/src/calibre/web/feeds/recipes/recipe_moneynews.py @@ -0,0 +1,49 @@ +#!/usr/bin/env python + +__license__ = 'GPL v3' +__copyright__ = '2009, Darko Miletic ' +''' +moneynews.newsmax.com +''' + +from calibre.web.feeds.news import BasicNewsRecipe + +class MoneyNews(BasicNewsRecipe): + title = 'Moneynews.com' + __author__ = 'Darko Miletic' + description = 'Financial news worldwide' + publisher = 'moneynews.com' + category = 'news, finances, USA, business' + oldest_article = 2 + max_articles_per_feed = 100 + no_stylesheets = True + use_embedded_content = False + encoding = 'cp1252' + + html2lrf_options = [ + '--comment', description + , '--category', category + , '--publisher', publisher + , '--ignore-tables' + ] + + html2epub_options = 'publisher="' + publisher + '"\ncomments="' + description + '"\ntags="' + category + '"\nlinearize_tables=True' + + feeds = [ + (u'Street Talk' , u'http://moneynews.newsmax.com/xml/streettalk.xml' ) + ,(u'Finance News' , u'http://moneynews.newsmax.com/xml/FinanceNews.xml' ) + ,(u'Economy' , u'http://moneynews.newsmax.com/xml/economy.xml' ) + ,(u'Companies' , u'http://moneynews.newsmax.com/xml/companies.xml' ) + ,(u'Markets' , u'http://moneynews.newsmax.com/xml/Markets.xml' ) + ,(u'Investing & Analysis' , u'http://moneynews.newsmax.com/xml/investing.xml' ) + ] + + + keep_only_tags = [dict(name='table', attrs={'class':'copy'})] + + remove_tags = [ + dict(name='td' , attrs={'id':'article_fontsize'}) + ,dict(name='table', attrs={'id':'toolbox' }) + ,dict(name='tr' , attrs={'id':'noprint3' }) + ] + \ No newline at end of file