Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Readers > Sony Reader

Notices

Reply
 
Thread Tools Search this Thread
Old 01-12-2010, 11:12 AM   #1
SharkDivingDiva
Junior Member
SharkDivingDiva began at the beginning.
 
Posts: 4
Karma: 10
Join Date: Jan 2010
Device: Sony PRS 600
NewB Needs Help Converting HTML to Sony reader format

Hi all! Thanks for offering so much help and advice on this forum!

I bought an ebook on B&N to test converting (<$5, my stepmom gave me B&N gift cards for Christmas). I was able to use ereadertohtml to remove the DRM. I get a folder with book.html and several .png files. If I open book.html in firefox, it looks great.

How do I convert the html to an epub format? I tried using Calibre, but it put ? where there should be ' or ". It's readable but annoying.

I should mention that I'm using a MacBookPro.

In one of the threads I saw someone state they strip the drm, then convert to html, edit the html, then just rezip and rename the .zip to .epub. That doesn't work with the standard mac compression tool, the resulting epub file is "corrupt" according to sony reader library.

Any help would be greatly appreciated!
SharkDivingDiva is offline   Reply With Quote
Old 01-12-2010, 11:41 AM   #2
gwynevans
Wizzard
gwynevans ought to be getting tired of karma fortunes by now.gwynevans ought to be getting tired of karma fortunes by now.gwynevans ought to be getting tired of karma fortunes by now.gwynevans ought to be getting tired of karma fortunes by now.gwynevans ought to be getting tired of karma fortunes by now.gwynevans ought to be getting tired of karma fortunes by now.gwynevans ought to be getting tired of karma fortunes by now.gwynevans ought to be getting tired of karma fortunes by now.gwynevans ought to be getting tired of karma fortunes by now.gwynevans ought to be getting tired of karma fortunes by now.gwynevans ought to be getting tired of karma fortunes by now.
 
gwynevans's Avatar
 
Posts: 1,402
Karma: 2000000
Join Date: Nov 2007
Location: UK
Device: iPad 2, iPhone 6s, Kindle Voyage & Kindle PaperWhite
Now, I'm not an expert here, so I could well be wrong, but...

Calibre's probably the way to focus your efforts, as the quotes to '?' sounds like a encoding issue and it might be able to tweak the conversion there in order to get it working but it'd be tricky to advise without seeing the html source/example.

A straightforward re-zip won't result in a valid ePub - there's a little more than that - see https://www.mobileread.com/forums/showthread.php?t=55681 for one solution.

You could try something like Sigil to try things, as that should let you produce ePubs from HTML, although not quite as easily as Calibre - not trying to criticize it, as it's targeted at different use cases - but might well be worth a look.
gwynevans is offline   Reply With Quote
Advert
Old 01-12-2010, 11:53 AM   #3
Kolenka
<Insert Wit Here>
Kolenka ought to be getting tired of karma fortunes by now.Kolenka ought to be getting tired of karma fortunes by now.Kolenka ought to be getting tired of karma fortunes by now.Kolenka ought to be getting tired of karma fortunes by now.Kolenka ought to be getting tired of karma fortunes by now.Kolenka ought to be getting tired of karma fortunes by now.Kolenka ought to be getting tired of karma fortunes by now.Kolenka ought to be getting tired of karma fortunes by now.Kolenka ought to be getting tired of karma fortunes by now.Kolenka ought to be getting tired of karma fortunes by now.Kolenka ought to be getting tired of karma fortunes by now.
 
Kolenka's Avatar
 
Posts: 1,017
Karma: 1275899
Join Date: Jan 2008
Location: Puget Sound
Device: Kindle Oasis, Kobo Forma
ePub uses a very specific layout of HTML, and some XML metadata to do its work (the metadata is where information like the author, the table of contents and other information lives).

What'd I'd recommend is fixing up the quotes (you can do search/replace in an editor like TextMate or really any proper programmer's text editor), and running it through calibre again.
Kolenka is offline   Reply With Quote
Old 01-12-2010, 01:02 PM   #4
rkelac
Member
rkelac began at the beginning.
 
Posts: 16
Karma: 14
Join Date: Dec 2009
Device: Sony 600
There is a line that has to be changed in ereader2html to fix this smartquote problem. I'll try to find it or you could search for smartquotes on the Calibre forum.
rkelac is offline   Reply With Quote
Old 01-12-2010, 01:09 PM   #5
SharkDivingDiva
Junior Member
SharkDivingDiva began at the beginning.
 
Posts: 4
Karma: 10
Join Date: Jan 2010
Device: Sony PRS 600
Rkelac, I couldn't find a reference to this in the Calibre forum. Please let me know if you can find the line in ereader2html, I know very little about programming/writing/changing scripts! Thanks!
SharkDivingDiva is offline   Reply With Quote
Advert
Old 01-12-2010, 01:52 PM   #6
gwynevans
Wizzard
gwynevans ought to be getting tired of karma fortunes by now.gwynevans ought to be getting tired of karma fortunes by now.gwynevans ought to be getting tired of karma fortunes by now.gwynevans ought to be getting tired of karma fortunes by now.gwynevans ought to be getting tired of karma fortunes by now.gwynevans ought to be getting tired of karma fortunes by now.gwynevans ought to be getting tired of karma fortunes by now.gwynevans ought to be getting tired of karma fortunes by now.gwynevans ought to be getting tired of karma fortunes by now.gwynevans ought to be getting tired of karma fortunes by now.gwynevans ought to be getting tired of karma fortunes by now.
 
gwynevans's Avatar
 
Posts: 1,402
Karma: 2000000
Join Date: Nov 2007
Location: UK
Device: iPad 2, iPhone 6s, Kindle Voyage & Kindle PaperWhite
Quote:
Originally Posted by SharkDivingDiva View Post
Rkelac, I couldn't find a reference to this in the Calibre forum. Please let me know if you can find the line in ereader2html, I know very little about programming/writing/changing scripts! Thanks!
I had a quick look and found the following options:

1) http://calibre-ebook.com/user_manual...r-smart-quotes - Try solution 2

or

2) Editing the ereader2html script - https://www.mobileread.com/forums/sho...252#post534936
gwynevans is offline   Reply With Quote
Old 01-12-2010, 03:16 PM   #7
SharkDivingDiva
Junior Member
SharkDivingDiva began at the beginning.
 
Posts: 4
Karma: 10
Join Date: Jan 2010
Device: Sony PRS 600
Thanks for all of your help! I tried the calibre solution 2 suggested by gwynevans, changed the html file input to cp1252, and it worked! I think the link she posted for changing the ereader2html script is what rkelac mentioned, I think it would work also because it sets the HTML file format to cp1252 when it is created. Thanks!!!
SharkDivingDiva is offline   Reply With Quote
Old 01-12-2010, 06:01 PM   #8
rkelac
Member
rkelac began at the beginning.
 
Posts: 16
Karma: 14
Join Date: Dec 2009
Device: Sony 600
Quote:
Originally Posted by SharkDivingDiva View Post
Thanks for all of your help! I tried the calibre solution 2 suggested by gwynevans, changed the html file input to cp1252, and it worked! I think the link she posted for changing the ereader2html script is what rkelac mentioned, I think it would work also because it sets the HTML file format to cp1252 when it is created. Thanks!!!
Yes, the second one is the one I was thinking of.
rkelac is offline   Reply With Quote
Reply

Tags
convert html to epub


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Converting e-reader secured books to sony format Eliab Sony Reader 5 06-26-2009 11:13 AM
Converting PDF to Sony format estral Sony Reader 22 04-29-2009 06:57 AM
How to convert MS Reader format to a compatible format on Sony Reader 505? lizzybeth05 LRF 18 03-01-2009 05:30 PM
Format for HTML to reader Schmots Sony Reader 7 05-12-2008 09:08 PM
Problem converting LIT to Sony Reader format. alophind Sony Reader 4 08-27-2007 11:31 AM


All times are GMT -4. The time now is 04:20 AM.


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