3

I have an ebook in EPUB format.

I want to publish it online as a set of interlinked HTML pages (what may be better than EPUB for both online readers and search engines).

What (free) software (either running on a Linux server or creating static HTML pages on a Linux PC) can you recommend for creating this Web site from EPUB?

I am a programmer and can write something myself, but I would prefer ready to use and professional software.

  • I have not tested it for that, but you might wish to take a look at Calibre – which can convert all kind of eBook formats. I use it the other way around (converting HTML to EPUB), but it should work for your task as well. – Izzy Jul 8 '15 at 19:10
  • @Izzy Calibre creates one big HTML file. But I want hyperlinked pages – porton Jul 8 '15 at 19:48
  • Ah, OK. See, that's why I've made it a comment rather than an answer :) Not sure if there're options to have Calibre creating multiple files (one per "chapter") and a hyper-linked index, but I guess you've already checked that. – Izzy Jul 9 '15 at 9:46
  • I recently dove into an ePub to discover that it is a folder containing (among other things) XHTML with the actual content (google.nl/search?q=epub+structure). Maybe you are already halfway with that knowledge ;-) – user416 Sep 8 '15 at 10:18
1

I have used SIGIL for developing epub books. First I have developed the content with Pressbooks then exported to EPUB format. Then I use SIGIL for the purpose of editing the content which will be more like a tree structure. Since this EPUB editor will help you traverse the essential chapters you can also edit the content and links easily in the code view. It support EPUB2 and EPUB3.

You should do the following steps:

  1. Import the EPUB file to the SIGIL
  2. Make the necessary modifications using the Code view
  3. Export to HTML

Check the link for additional reference.

0

Pandoc can do this nicely for you with the basic options or you can do a lot of tweaking via the command line options and the templates.

However with the limitation of it being a single big html file or fragment. Personally I would then use a python script to split this into multiple html files on the <H1>, or possibly lower levels, each with a pre/contents/next links build up the TOC along the way. To do this I would probably use BeautifulSoup as it should be reasonably simple to isolate the chapters, generate the links, etc. The main question is do you wish to split lower than the <H1> tags and if so do you put the first sub-section in the same file as the <H1> content.

  • I skimmed through pandoc manpage. It seems that pandoc does not support output into multiple HTML files, what is what I want. It supports only output of a single big HTML files, what is not what I want. – porton Jul 9 '15 at 13:02

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.