01-23-2011, 08:23 AM | #1 |
Junior Member
Posts: 6
Karma: 10
Join Date: Jan 2011
Device: Kindle 3
|
Problem with ISO-8859-1 charset
I've done a recipe that download news from yahoo fees rss (Italy version).
It looks great on my kindle after an advanced scripting using calibre, but i've got a problem: if you look at the html of this example page http://it.notizie.yahoo.com/35/20110...o-5101f32.html you will found that the charset is "charset=ISO-8859-1". So in my recipe I've added the script <encoding = 'iso-8859-1'>, but there are some error in characters, for example the string in the page "all’uscita" is translated to "all?uscita"; i also tried to use the scripts <encoding = 'utf8'>, <encoding = 'utf-8'> or to not insert the script <encoding> but the result is the same. What encoding I've to use? Could you help me please? Thanks in advance. |
01-23-2011, 08:33 AM | #2 |
Junior Member
Posts: 6
Karma: 10
Join Date: Jan 2011
Device: Kindle 3
|
Wait a moment...
Now I've tried to use the encoding 'cp1252' and it seems that it has resolved my problem.. |
Advert | |
|
01-24-2011, 06:13 PM | #3 |
Junior Member
Posts: 6
Karma: 10
Join Date: Jan 2011
Device: Kindle 3
|
Ok now the conversione with the GUI of calibre work, but if i try to do a conversion via MSDOS (I use windows versione of Calibre on Windows 7 SO) trought the command:
ebook-convert.exe myRecipe.recipe converted.mobi program gives me this error: 1% Conversione dell'input in HTML... InputFormatPlugin: Recipe Input running Python function terminated unexpectedly 'utf8' codec can't decode byte 0xe0 in position 1766: invalid continuation byt e (Error Code: 1) Traceback (most recent call last): File "site.py", line 103, in main File "site.py", line 85, in run_entry_point File "site-packages\calibre\ebooks\conversion\cli.py", line 278, in main File "site-packages\calibre\ebooks\conversion\plumber.py", line 897, in run File "site-packages\calibre\customize\conversion.py", line 204, in __call__ File "site-packages\calibre\web\feeds\input.py", line 68, in convert File "site-packages\calibre\web\feeds\recipes\__init__.py", line 35, in compil e_recipe File "encodings\utf_8.py", line 16, in decode UnicodeDecodeError: 'utf8' codec can't decode byte 0xe0 in position 1766: invali d continuation byte and the conversion is stopped.. It's seem like that encoding rule 'cp1252' in recipe breaks something in ebook-convert.exe command. Coul you help me please? Carlo |
01-24-2011, 07:31 PM | #4 |
creator of calibre
Posts: 43,851
Karma: 22666666
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
you need to ensure that your .recipe file is saved in utf-8 encoding
|
01-25-2011, 04:14 AM | #5 |
Junior Member
Posts: 6
Karma: 10
Join Date: Jan 2011
Device: Kindle 3
|
Thanks!
PsPad by default saves file in ANSI format; in utf8 works! Last edited by cafedo; 01-25-2011 at 04:29 AM. |
Advert | |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
PDF is now an ISO Standard | Bob Russell | News | 2 | 12-06-2007 01:00 PM |