Register Guidelines E-Books Search Today's Posts Mark Forums Read

Go Back   MobileRead Forums > E-Book Software > Calibre > Recipes

Notices

Reply
 
Thread Tools Search this Thread
Old 10-31-2010, 01:37 PM   #1
jmst
Active lurker
jmst began at the beginning.
 
Posts: 2
Karma: 10
Join Date: Oct 2010
Location: Portugal
Device: none
Calibre recipe for daily Portuguese newspaper "Correio da Manhã"

The best-selling daily Portuguese newspaper. Works for Kindle, includes pics, but there is room for improvement.
Enjoy.


__license__ = 'GPL v3'
__copyright__ = '2010, Darko Miletic <darko.miletic at gmail.com>'
'''
www.cmjornal.xl.pt
'''

from calibre.web.feeds.news import BasicNewsRecipe

class CMJornal_pt(BasicNewsRecipe):
title = 'Correio da Manha - Portugal'
__author__ = 'Correio da Manha'
description = 'As noticias de Portugal e do Mundo'
publisher = 'Cofina Media'
category = ''
oldest_article = 1
no_stylesheets = True
encoding = 'utf-8'
use_embedded_content = False
language = 'pt'
extra_css = ' .publish{font-style: italic; line-height: 1.2em; border-bottom: 1px dotted; padding: 5px 0} .entity{line-height: 1.2em} .overview{line-height:1.2em} '

conversion_options = {
'comment' : description
, 'tags' : category
, 'publisher' : publisher
, 'language' : language
}

keep_only_tags = [
dict(name=['h2','h1'])
, dict(name='div', attrs={'class': ['news']})
]

remove_tags = [
dict(name=['object','embed','iframe'])
,dict(name='a',attrs={'href':['#']})
]

feeds = [
(u'Actualidade' , u'http://www.cmjornal.xl.pt/rss/rss.aspx?channelID=00000009-0000-0000-0000-000000000009' )
,(u'Portugal' , u'http://www.cmjornal.xl.pt/rss/rss.aspx?channelID=00000010-0000-0000-0000-000000000010' )
,(u'Economia' , u'http://www.cmjornal.xl.pt/rss/rss.aspx?channelID=00000011-0000-0000-0000-000000000011' )
,(u'Mundo' , u'http://www.cmjornal.xl.pt/rss/rss.aspx?channelID=00000091-0000-0000-0000-000000000091' )
,(u'Desporto' , u'http://www.cmjornal.xl.pt/rss/rss.aspx?channelID=00000012-0000-0000-0000-000000000012' )
,(u'TV & Media', u'http://www.cmjornal.xl.pt/rss/rss.aspx?channelID=00000092-0000-0000-0000-000000000092')
]

def print_version(self, url):
return url.replace('noticia.aspx', 'Imprimir.aspx')
jmst is offline   Reply With Quote
Old 10-31-2010, 02:00 PM   #2
Starson17
Wizard
Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.
 
Posts: 4,004
Karma: 177841
Join Date: Dec 2009
Device: WinMo: IPAQ; Android: HTC HD2, Archos 7o; Java:Gravity T
Quote:
Originally Posted by jmst View Post
The best-selling daily Portuguese newspaper. Works for Kindle, includes pics, but there is room for improvement.
Enjoy.
You need to repost it inside of CODE tags (the # Hash symbol) to let people enjoy it. They need the indents.

Last edited by Starson17; 11-01-2010 at 01:33 PM. Reason: Stupidly wrote QUOTE when meant CODE
Starson17 is offline   Reply With Quote
Advert
Old 11-01-2010, 01:01 PM   #3
jmst
Active lurker
jmst began at the beginning.
 
Posts: 2
Karma: 10
Join Date: Oct 2010
Location: Portugal
Device: none
OMG, last attempt didn't seem to be successful...
Save the attached file as cmjornal.recipe, and upload it into Calibre.
Attached Files
File Type: txt cmjornal.recipe.txt (2.2 KB, 407 views)
jmst is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Daily Austrian Newspaper "derStandard" as Ebook laborg Workshop 2 10-12-2010 08:48 AM
Getting calibre to detect "Prologue" and "Epilogue" for TOC sherman Calibre 2 09-20-2010 02:21 AM
Classic Australian Daily Telegraph "Smart Edition" and the nook? firefox Barnes & Noble NOOK 0 07-19-2010 02:50 AM
UK Daily Telegraph "Ebooks will make authors soulless, just like their product" Sparrow News 46 09-18-2009 06:55 PM
Is it possible to read newspaper with Digital Reader 1000S, "wisely" haja0011 iRex 4 07-22-2009 05:57 AM


All times are GMT -4. The time now is 03:27 PM.


MobileRead.com is a privately owned, operated and funded community.