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

  1. from calibre.web.feeds.news import BasicNewsRecipe
  2.  
  3. class IndianExpress(BasicNewsRecipe):
  4.     title          = u'Indian Express'
  5.     language       = 'en_IN'
  6.     __author__     = 'Krittika Goyal'
  7.     oldest_article = 1 #days
  8.     max_articles_per_feed = 25
  9.     encoding = 'cp1252'
  10.  
  11.     no_stylesheets = True
  12.     remove_tags_before = dict(name='div', attrs={'class':'top_head'})
  13.     #remove_tags_after  = dict(name='td', attrs={'class':'newptool1'})
  14.     remove_tags = [
  15.        dict(name='iframe'),
  16.        dict(name='div', attrs={'class':['bookmarks_div', 'comment_box', 'bookmarks_div_bot', 'box']}),
  17.        dict(name='div', attrs={'id':['footer', 'tab_innerhc', 'discussion', 'google_new']}),
  18.        dict(name='a', attrs={'class':'nobdr'}),
  19.        #dict(name='span', text=':'),
  20.     ]
  21.  
  22.     feeds          = [
  23. ('Front Page',
  24.  'http://syndication.indianexpress.com/rss/33/front-page.xml'),
  25. ('Markets',
  26.  'http://syndication.indianexpress.com/rss/793/markets.xml'),
  27. ('Editorials',
  28.  'http://syndication.indianexpress.com/rss/35/editorials.xml'),
  29. ('Crime',
  30.  'http://syndication.indianexpress.com/rss/801/crime-&-justice.xml'),
  31. ('Cricket',
  32.  'http://syndication.indianexpress.com/rss/777/cricket.xml'),
  33. ('Health',
  34.  'http://syndication.indianexpress.com/rss/697/health.xml'),
  35. ('Asia',
  36.  'http://syndication.indianexpress.com/rss/790/asia.xml'),
  37. ('Politics',
  38.  'http://syndication.indianexpress.com/rss/799/politics.xml'),
  39. ('Mumbai',
  40.  'http://syndication.indianexpress.com/rss/707/mumbai.xml'),
  41. ('Op-Ed',
  42.  'http://syndication.indianexpress.com/rss/36/oped.xml'),
  43. ('Economy',
  44.  'http://syndication.indianexpress.com/rss/794/economy.xml'),
  45. ('Lifestyle',
  46.  'http://syndication.indianexpress.com/rss/713/lifestyle.xml'),
  47. ('Letters to the Editor',
  48.  'http://syndication.indianexpress.com/rss/40/letters-to-editor.xml'),
  49. ('Movie Reviews',
  50.  'http://syndication.indianexpress.com/rss/665/movie-reviews.xml'),
  51. ('Bollywood',
  52.  'http://syndication.indianexpress.com/rss/887/bollywood.xml'),
  53. ]
  54.  
  55.     def print_version(self, url):
  56.         return url+'/0'
  57.  
  58.