__license__ = 'GPL v3' __copyright__ = '2010-2014, Darko Miletic ' ''' radikal.com.tr ''' from calibre.web.feeds.news import BasicNewsRecipe class Radikal_tr(BasicNewsRecipe): title = 'Radikal - Turkey' __author__ = 'Darko Miletic' description = 'News from Turkey' publisher = 'radikal' category = 'news, politics, Turkey' oldest_article = 2 max_articles_per_feed = 150 no_stylesheets = True use_embedded_content = False remove_empty_feeds = True auto_cleanup = False masthead_url = 'http://www.radikal.com.tr/D/i/1/V2/radikal_logo.jpg' language = 'tr' publication_type = 'newspaper' extra_css = """ @font-face {font-family: "sans1";src:url(res:///opt/sony/ebook/FONT/tt0003m_.ttf)} body{font-family: 'PT Sans',Arial,Helvetica,sans1,sans-serif} """ conversion_options = { 'comment': description, 'tags': category, 'publisher': publisher, 'language': language } remove_tags = [ dict(name=['meta', 'iframe', 'embed', 'object', 'link', 'base']), dict(name='div', attrs={ 'class': ['options', 'news_related', 'browserWidth_shareBox']}), dict(attrs={'class': ['breadcrumb clearfix', 'box_title']}) ] keep_only_tags = [ dict(attrs={'class': ['news-content-header', 'news-content-text clearfix', 'author-content-text', 'news_detail_top', 'news_article']}) ] feeds = [ (u'Yazarlar', u'http://www.radikal.com.tr/d/rss/RssYazarlar.xml'), (u'Türkiye', u'http://www.radikal.com.tr/d/rss/Rss_77.xml'), (u'Politika', u'http://www.radikal.com.tr/d/rss/Rss_78.xml'), (u'Dünya', u'http://www.radikal.com.tr/d/rss/Rss_81.xml'), (u'Ekonomi', u'http://www.radikal.com.tr/d/rss/Rss_80.xml'), (u'Radikal 2', u'http://www.radikal.com.tr/d/rss/Rss_42.xml'), (u'Radikal Hayat', u'http://www.radikal.com.tr/d/rss/Rss_41.xml'), (u'Radikal Kitap', u'http://www.radikal.com.tr/d/rss/Rss_40.xml'), (u'Spor', u'http://www.radikal.com.tr/d/rss/Rss_84.xml') ]