home *** CD-ROM | disk | FTP | other *** search
/ Chip 2011 November / CHIP_2011_11.iso / Programy / Narzedzia / Calibre / calibre-0.8.18.msi / file_280 / bugun_gazetesi.recipe < prev    next >
Encoding:
Text File  |  2011-09-09  |  3.4 KB  |  58 lines

  1. # -*- coding: utf-8 -*-
  2.  
  3. from calibre.web.feeds.news import BasicNewsRecipe
  4.  
  5. class Bugun (BasicNewsRecipe):
  6.  
  7.     title                  = u'BUG├£N Gazetesi'
  8.     __author__             = u'thomass'
  9.     oldest_article         = 2
  10.     max_articles_per_feed  =100
  11.     #no_stylesheets         = True
  12.     #delay                  = 1
  13.     use_embedded_content   = False
  14.     encoding               = 'UTF-8'
  15.     publisher              = 'thomass'
  16.     category               = 'news, haberler,TR,gazete'
  17.     language               = 'tr'
  18.     publication_type = 'newspaper '
  19.     extra_css              = ' div{font-size: small} h2{font-size: small;font-weight: bold} #ctl00_ortayer_haberBaslik{font-size:20px;font-weight: bold} '#h1{ font-size:10%;font-weight: bold} '#ctl00_ortayer_haberBaslik{ 'font-size:10%;font-weight: bold'}
  20.     #introduction{} .story-feature{display: block; padding: 0; border: 1px solid; width: 40%; font-size: small} .story-feature h2{text-align: center; text-transform: uppercase} '
  21.     conversion_options = {
  22.                             'tags'            : category
  23.                             ,'language'        : language
  24.                             ,'publisher'       : publisher
  25.                             ,'linearize_tables': True
  26.                          }
  27.     cover_img_url = 'http://www.bugun.com.tr/images/bugunLogo2011.png'
  28.     masthead_url = 'http://www.bugun.com.tr/images/bugunLogo2011.png'
  29.  
  30.     keep_only_tags      = [dict(name='h1', attrs={'class':[ 'haberBaslik']}),dict(name='h2', attrs={'class':[ 'haberOzet']}), dict(name='div', attrs={'class':['haberGriDivvvv']}), dict(name='div', attrs={'id':[ 'haberTextDiv']}), ]
  31.  
  32.     #keep_only_tags      = [dict(name='div', attrs={'id':[ 'news-detail-content']}), dict(name='td', attrs={'class':['columnist-detail','columnist_head']})  ]
  33.     #remove_tags = [ dict(name='div', attrs={'id':['news-detail-news-text-font-size','news-detail-gallery','news-detail-news-bottom-social']}),dict(name='div', attrs={'class':['radioEmbedBg','radyoProgramAdi']}),dict(name='a', attrs={'class':['webkit-html-attribute-value webkit-html-external-link']}),dict(name='table', attrs={'id':['yaziYorumTablosu']}),dict(name='img', attrs={'src':['http://medya.zaman.com.tr/pics/paylas.gif','http://medya.zaman.com.tr/extentions/zaman.com.tr/img/columnist/ma-16.png']})]
  34.  
  35.  
  36.     #remove_attributes = ['width','height']
  37.     remove_empty_feeds= True
  38.  
  39.     feeds          = [
  40.                       ( u'Son Dakika', u'http://www.bugun.com.tr/haberler.xml'),
  41.                      ( u'Yazarlar', u'http://www.bugun.com.tr/rss/yazarlar.xml'),
  42.                      ( u'G├╝ndem', u'http://www.bugun.com.tr/rss/gundem.xml'),
  43.                      ( u'Ekonomi', u'http://www.bugun.com.tr/rss/ekonomi.xml'),
  44.                      ( u'Spor', u'http://www.bugun.com.tr/rss/spor.xml'),
  45.                      ( u'Magazin', u'http://www.bugun.com.tr/rss/magazin.xml'),
  46.                      ( u'Teknoloji', u'http://www.bugun.com.tr/rss/teknoloji.xml'),
  47.                      ( u'Ya┼ƒam', u'http://www.bugun.com.tr/rss/yasam.xml'),
  48.                      ( u'Medya', u'http://www.bugun.com.tr/rss/medya.xml'),
  49.                      ( u'D├╝nya', u'http://www.bugun.com.tr/rss/dunya.xml'),
  50.                      ( u'Politika', u'http://www.bugun.com.tr/rss/politika.xml'),
  51.                      ( u'Sa─ƒl─▒k', u'http://www.bugun.com.tr/rss/saglik.xml'),
  52.                      ( u'Tarifler', u'http://www.bugun.com.tr/rss/yemek-tarifi.xml'),
  53.  
  54.  
  55.  
  56.  
  57.                         ]
  58.