![]() |
#1 |
Connoisseur
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 83
Karma: 499304
Join Date: Jul 2011
Device: Kindle
|
Problem with html -> Mobi conversion - html tags visible.
I am having some trouble using .html (zip) -> .mobi conversion.
As soon as I enable post-processing (and check any of the alternatives) my resulting mobi loses all formatting and outputs html tags in cleartext (see picture below) ![]() This is happening consistently with multiple html files, Calibre 0.8.12 on Win7. I apologize if I posted this in the incorrect section. Edit: also, my heading is wrong. It's supposed to be html -> mobi and nothing else. Moderator Notice
Fixed title per your request Last edited by theducks; 08-04-2011 at 08:31 PM. |
![]() |
![]() |
![]() |
#2 |
Grand Sorcerer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 6,246
Karma: 16539642
Join Date: Sep 2009
Location: UK
Device: ClaraHD, Forma, Libra2, Clara2E, LibraCol, PBTouchHD3
|
Without access to the .zip file it's hard to say, but that <pre> tag on line 2 is suspicious. Where is its matching </pre> tag?
<pre> tags normally mean 'show this text as-is' i.e. you wouldn't expect to see <b> and <i> tags inside <pre>...</pre> tags. |
![]() |
![]() |
Advert | |
|
![]() |
#3 | |
Well trained by Cats
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 30,883
Karma: 59840450
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
|
Quote:
|
|
![]() |
![]() |
![]() |
#4 |
Resident Curmudgeon
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 78,948
Karma: 144284074
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
|
Try turning off post-processing. I don't use it and don't have these problems.
|
![]() |
![]() |
![]() |
#5 | ||
Connoisseur
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 83
Karma: 499304
Join Date: Jul 2011
Device: Kindle
|
Quote:
Quote:
![]() Besides, <pre> tags are only for keeping spaces and line breaks as they are in the HTML (and Calibre should probably remove the pre tags when you perform unwrapping.) See: http://www.w3schools.com/tags/tag_pre.asp |
||
![]() |
![]() |
Advert | |
|
![]() |
#6 | |
Well trained by Cats
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 30,883
Karma: 59840450
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
|
Quote:
What is in the CODE? Perhaps: ![]() Code:
<pre> << this one will not show in the book view <p></p> <pre>... </pre> << this one will not show in the book either </html> </body> I have used Pre tags before ![]() |
|
![]() |
![]() |
![]() |
#7 |
Resident Curmudgeon
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 78,948
Karma: 144284074
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
|
One thing is don't use <pre> tags. On most readers, they don't work properly because if they are too wide for the screen, there's no way to scroll left/right to see what's off the screen. Convert <pre> into <div>.
|
![]() |
![]() |
![]() |
#8 |
Resident Curmudgeon
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 78,948
Karma: 144284074
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
|
|
![]() |
![]() |
![]() |
#9 | |
Connoisseur
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 83
Karma: 499304
Join Date: Jul 2011
Device: Kindle
|
Quote:
Since this is happening over multiple tested html files, regarding of whether the <pre> tag is actually to blame I think the issue needs to be looked over to see if there is a problem with BeautifulSoup or other internal component of Calibre. As for posting the actual file, I'm not sure if it would be allowed under site rules, but you can simply try saving this page as a html file and import it into Calibre to recreate the issue: http://www.imsdb.com/scripts/Gattaca.html (Convert html -> mobi and enable any of the post-processing options to recreate issue.) |
|
![]() |
![]() |
![]() |
#10 |
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,613
Karma: 6718541
Join Date: Dec 2004
Location: Paradise (Key West, FL)
Device: Current:Surface Go & Kindle 3 - Retired: DellV8p, Clie UX50, ...
|
You should NOT rely on Calibre's ebook viewer to preview/test an ebook conversion, particularly MOBI conversions.
To properly preview/text a MOBI file you should use either a Kindle device or the Kindle Previewer. The latter is a special software viewer that is designed to replicate the display on the device. The current version can replicate the K3, KDXG, Kindle for iPob, & Kindle for iPhone and is available free from this page: http://www.amazon.com/gp/feature.htm...cId=1000234621 Also, the <PRE>...</PRE> tag set specifies that all contents are pre-formatted. You can't reliably include any other HTML formatting tags inside of <PRE> section. When you do, they should be displayed by the browser/reader/viewer. |
![]() |
![]() |
![]() |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
.Txt -> .Html -> .Zip Problem | galagable | Conversion | 7 | 04-30-2011 06:05 AM |
Convert HTML to MOBI (HTML recognized as ZIP file) | pdubois | Conversion | 1 | 01-25-2011 12:55 PM |
problem with Office 2011 generated-html to zip | selmat | Conversion | 4 | 01-23-2011 06:13 PM |
HTML Conversion Problem | bigtymer | Calibre | 7 | 01-14-2010 08:15 PM |
Multiple html (zip) conversion no longer works | Katelyn | Calibre | 4 | 08-07-2009 11:52 AM |