Improved recipe for The Australian

This commit is contained in:
Kovid Goyal 2009-10-22 17:21:35 -06:00
parent 7b8bdfc3a8
commit cc92acadb8
2 changed files with 25 additions and 4 deletions

View File

@ -11,7 +11,7 @@ from calibre.web.feeds.news import BasicNewsRecipe
class DailyTelegraph(BasicNewsRecipe):
title = u'The Australian'
__author__ = u'Matthew Briggs'
__author__ = u'Matthew Briggs and Sujata Raman'
description = u'National broadsheet newspaper from down under - colloquially known as The Oz'
language = 'en_AU'
@ -34,6 +34,15 @@ class DailyTelegraph(BasicNewsRecipe):
remove_tags = [dict(name=['object','link'])]
extra_css = '''
h1{font-family :Georgia,"Times New Roman",Times,serif; font-size:large; }
#article{font-family :Georgia,"Times New Roman",Times,serif; font-size: x-small;}
.module-subheader{font-family :Tahoma,Geneva,Arial,Helvetica,sans-serif; color:#666666; font-size: xx-small;}
.intro{ font-family:Trebuchet MS,Trebuchet,Helvetica,sans-serif;font-size: x-small; }
.article-source{font-family:Trebuchet MS,Trebuchet,Helvetica,sans-serif; color:#666666; font-size: xx-small;}
.caption{font-family:Trebuchet MS,Trebuchet,Helvetica,sans-serif; font-size: xx-small;}
'''
feeds = [
(u'News', u'http://feeds.news.com.au/public/rss/2.0/aus_news_807.xml'),
(u'World News', u'http://feeds.news.com.au/public/rss/2.0/aus_world_808.xml'),
@ -53,3 +62,15 @@ class DailyTelegraph(BasicNewsRecipe):
(u'Property', u'http://feeds.news.com.au/public/rss/2.0/aus_property_59.xml'),
(u'US Election', u'http://feeds.news.com.au/public/rss/2.0/aus_uselection_687.xml')
]
def get_cover_url(self):
href = 'http://www.theaustralian.news.com.au/'
soup = self.index_to_soup(href)
img = soup.find('img',alt ="Digital editions of The Australian")
print img
if img :
cover_url = img['src']
return cover_url

View File

@ -5,8 +5,8 @@
msgid ""
msgstr ""
"Project-Id-Version: calibre 0.6.19\n"
"POT-Creation-Date: 2009-10-20 18:49+MDT\n"
"PO-Revision-Date: 2009-10-20 18:49+MDT\n"
"POT-Creation-Date: 2009-10-22 17:20+MDT\n"
"PO-Revision-Date: 2009-10-22 17:20+MDT\n"
"Last-Translator: Automatically generated\n"
"Language-Team: LANGUAGE\n"
"MIME-Version: 1.0\n"
@ -1831,7 +1831,7 @@ msgid "Specify the character encoding of the output document. The default is utf
msgstr ""
#: /home/kovid/work/calibre/src/calibre/ebooks/tcr/output.py:27
msgid "Speciy the compression level to use. Scale 1 - 10. 1 being the lowest compression but the fastest and 10 being the highest compression but the slowest."
msgid "Specify the compression level to use. Scale 1 - 10. 1 being the lowest compression but the fastest and 10 being the highest compression but the slowest."
msgstr ""
#: /home/kovid/work/calibre/src/calibre/ebooks/txt/input.py:32