Iniciar sesión

Ver la versión completa : La Razon - Noticias Generales (v0.1)



rickydh
07/02/2011, 00:47
__license__ = 'GPL v3'
__author__ = 'Ricardo Jurado'
__copyright__ = 'Ricardo Jurado'
__version__ = 'v0.1'
__date__ = '07 February 2011'

'''
http://www.larazon.es/
'''


class AdvancedUserRecipe1297031650(BasicNewsRecipe):

title = u'LARAZON.es'
publisher = u''

__author__ = 'Ricardo Jurado'
description = 'Noticias'

title = u'LARAZON.es'
oldest_article = 2
max_articles_per_feed = 20
no_stylesheets = True
use_embedded_content = False
encoding = 'UTF-8'
remove_javascript = True
language = 'es'

extra_css = """
p{text-align: justify; font-size: 100%}
body{ text-align: left; font-size:100% }
h3{font-family: sans-serif; font-size:120%; font-weight:bold; text-align: justify; }
h2{font-family: sans-serif; font-size:140%; font-weight:bold; text-align: justify; }
h1{font-family: sans-serif; font-size:150%; font-weight:bold; text-align: justify; }
"""

keep_only_tags = [
dict(name='div', attrs={'id':'solapas'}),
dict(name='div', attrs={'class':'txt'}),
dict(name='div', attrs={'class':'detalle-noticia'})
]

remove_tags = [
dict(name='div' , attrs={'class':['num-comentarios','clearFix dixio']})
]

remove_tags_after = [
dict(name='div' , attrs={'class':['detalle-noticia']})
]

feeds = [
(u'NOTICIAS GENERALES', u'http://www.larazon.es/rss')
]


--
Saludos.

KRorschachZ
09/02/2011, 19:21
__license__ = 'GPL v3'
__author__ = 'Ricardo Jurado'
__copyright__ = 'Ricardo Jurado'
__version__ = 'v0.1'
__date__ = '07 February 2011'

'''
http://www.larazon.es/
'''


class AdvancedUserRecipe1297031650(BasicNewsRecipe):

title = u'LARAZON.es'
publisher = u''

__author__ = 'Ricardo Jurado'
description = 'Noticias'

title = u'LARAZON.es'
oldest_article = 2
max_articles_per_feed = 20
no_stylesheets = True
use_embedded_content = False
encoding = 'UTF-8'
remove_javascript = True
language = 'es'

extra_css = """
p{text-align: justify; font-size: 100%}
body{ text-align: left; font-size:100% }
h3{font-family: sans-serif; font-size:120%; font-weight:bold; text-align: justify; }
h2{font-family: sans-serif; font-size:140%; font-weight:bold; text-align: justify; }
h1{font-family: sans-serif; font-size:150%; font-weight:bold; text-align: justify; }
"""

keep_only_tags = [
dict(name='div', attrs={'id':'solapas'}),
dict(name='div', attrs={'class':'txt'}),
dict(name='div', attrs={'class':'detalle-noticia'})
]

remove_tags = [
dict(name='div' , attrs={'class':['num-comentarios','clearFix dixio']})
]

remove_tags_after = [
dict(name='div' , attrs={'class':['detalle-noticia']})
]

feeds = [
(u'NOTICIAS GENERALES', u'http://www.larazon.es/rss')
]


--
Saludos.


Probada y chekeada, perfecto. ;-)