home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Chip 2011 November
/
CHIP_2011_11.iso
/
Programy
/
Narzedzia
/
Calibre
/
calibre-0.8.18.msi
/
file_280
/
credit_slips.recipe
< prev
next >
Wrap
Text File
|
2011-09-09
|
2KB
|
45 lines
#!/usr/bin/env python
__license__ = 'GPL 3'
__copyright__ = 'zotzo'
__docformat__ = 'restructuredtext en'
from calibre.web.feeds.news import BasicNewsRecipe
class CreditSlips(BasicNewsRecipe):
language = 'en'
__author__ = 'zotzot'
version = 2
title = u'Credit Slips.org'
publisher = u'Bankr-L'
category = u'Economic blog'
description = u'A discussion on credit and bankruptcy'
cover_url = 'http://bit.ly/eAKNCB'
oldest_article = 15
max_articles_per_feed = 100
use_embedded_content = True
no_stylesheets = True
remove_javascript = True
conversion_options = {
'comments': description,
'tags': category,
'language': 'en',
'publisher': publisher,
}
feeds = [
(u'Credit Slips', u'http://www.creditslips.org/creditslips/atom.xml')
]
extra_css = '''
.author {font-family:Helvetica,sans-serif; font-weight:normal;font-size:small;}
h1 {font-family:Arial,Helvetica,sans-serif; font-weight:bold;font-size:large;}
p {font-family:Helvetica,Arial,sans-serif;font-size:small;}
body {font-family:Helvetica,Arial,sans-serif;font-size:small;}
'''
def populate_article_metadata(self, article, soup, first):
h2 = soup.find('h2')
h2.replaceWith(h2.prettify() + '<p><em>Posted by ' + article.author + '</em></p>')