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

  1.  
  2. __license__   = 'GPL v3'
  3. __copyright__ = '2010, Darko Miletic <darko.miletic at gmail.com>'
  4. '''
  5. www.nst.com.my
  6. '''
  7.  
  8. from calibre.web.feeds.news import BasicNewsRecipe
  9.  
  10. class Newstraitstimes(BasicNewsRecipe):
  11.     title                 = 'New Straits Times from Malaysia'
  12.     __author__            = 'Darko Miletic'
  13.     description           = 'Learning Curve, Sunday People, New Straits Times from Malaysia'
  14.     publisher             = 'nst.com.my'
  15.     category              = 'news, politics, Malaysia'
  16.     oldest_article        = 2
  17.     max_articles_per_feed = 100
  18.     no_stylesheets        = True
  19.     encoding              = 'cp1252'
  20.     use_embedded_content  = False
  21.     language              = 'en'
  22.     masthead_url          = 'http://www.nst.com.my/Current_News/NST/Images/new-nstonline.jpg'
  23.  
  24.     conversion_options = {
  25.                           'comment'   : description
  26.                         , 'tags'      : category
  27.                         , 'publisher' : publisher
  28.                         , 'language'  : language
  29.                         }
  30.  
  31.     remove_tags       = [dict(name=['link','table'])]
  32.     keep_only_tags = dict(name='div',attrs={'id':'haidah'})
  33.  
  34.     feeds = [(u'Articles', u'http://www.nst.com.my/rss/allSec')]
  35.  
  36.