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

  1.  
  2. __license__   = 'GPL v3'
  3. __copyright__ = '2010, Darko Miletic <darko.miletic at gmail.com>'
  4. '''
  5. orsai.bitacoras.com
  6. '''
  7.  
  8. from calibre.web.feeds.news import BasicNewsRecipe
  9.  
  10. class Orsai(BasicNewsRecipe):
  11.     title                 = 'Orsai'
  12.     __author__            = 'Darko Miletic'
  13.     language = 'es'
  14.     oldest_article        = 35
  15.     max_articles_per_feed = 100
  16.     encoding              = 'utf-8'
  17.     no_stylesheets        = True
  18.     use_embedded_content  = False
  19.     publication_type      = 'blog'
  20.     masthead_url          = 'http://orsai.bitacoras.com/wp-content/themes/orsai/images/logo_orsai.png'
  21.  
  22.     conversion_options = {
  23.                           'comment'  : 'Blog literario de Hern├ín Casciari'
  24.                         , 'tags'     : 'blog, Argentina, Espa├▒a, literatura, Casciari'
  25.                         , 'publisher': 'Editorial Orsai S.L.'
  26.                         , 'language' : 'es'
  27.                         }
  28.  
  29.     keep_only_tags=[dict(attrs={'class':['entry-title','entry-meta','entry-content','commentlist']})]
  30.     remove_tags=[dict(name='img',attrs={'class':'avatar avatar-40 photo'})]
  31.     feeds = [(u'Articulos', u'http://orsai.bitacoras.com/feed')]
  32.  
  33.     def preprocess_html(self, soup):
  34.         for item in soup.findAll(style=True):
  35.             del item['style']
  36.         return self.adeify_images(soup)
  37.  
  38.