How to Convert ePub eBooks with Kompozer

Share this article

For some weeks now I have been looking for a way to convert my PDF’s into eBooks.

Since PDF’s are based on images turning them into text means you will lose the PDF layout. It actually turned out to be a real pain in the butt. At first I thought that by using free conversion software and turning the PDF into a ePub format would do the trick. However I ended up with raw text files that really didn’t look to good. My goal is to turn these eBooks into mobile apps.

Well, it never occurred to me that ePub files are actually .zip files and that by extracting the .html content from them I can edit them easily in Kompozer (or whatever html editor you are using)! The below article from Howtogeek.com explains it in detail:

[loveclaw_buttons]

Edit ePub eBooks With Your Favorite HTML Editor

ePub eBooks are increasingly popular today, but often they’ve been made by converting other file formats. Here’s how you can edit ePub books to remove irregularities and make them better for reading on your devices.

ePub’s are actually a zip file containing images, XHTML files with your text, and more with the .epub extension. You can make them better by editing the XHTML files directly. Code gurus can edit the code directly, but even if you’ve never edited HTML, you can still quickly make changes with a WYSIWYG editor.

Extract the Files from your ePub eBook

As mentioned before, ePub files are actually renamed zip files. So first let’s get all of the files in your ePub eBook accessible. Find an eBook you want to edit and then change the file extension to .zip.

If you don’t see the file extensions, click Organize in the menu bar and select Folder and search options.

Select the View tab, and then uncheck the box beside Hide extensions for known file types. Click Ok, and then change the file type as above.

Windows will warn you about changing the file type; click Yes to proceed.

Now you can browse the files of the ePub file. Notice that it contains mostly HTML or XHTML files and images. Click Extract all files to save them all in a folder so you can easily edit them.

Alternately, you can open the ePub file directly in your favorite file archival program such as 7-zip. Browse to the location of your ePub file, double-click it, and it’ll automatically open even if you don’t change the file extension to zip. Now you can extract the folder, or extract individual files as before.

Edit Your eBook in KompoZer

The actual ebook contents are stored in HTML or XHTML files. These may be stored on the top folder of you ePub file’s directory, or they may be stored in \OEBPS\text in the file.

To change the contents of your eBook, you’ll want to edit these files. Often there may be separate files for each chapter, so you may have to use trial and error to find the one you need to edit. You could edit them by hand in Windows using Notepad if you don’t have an HTML editor installed.

A better option would be to use an HTML editor. Here we’ll use the free KompoZer program to edit the files just like we’d edit a document in Word.

Download KompoZer (link below), and unzip the files. Then open the new folder and launch kompozer.exe; you don’t even need to install it. In fact, you could even store KompoZer on a flash drive so you could edit HTML files from any computer.

In KompoZer, open the HTML or XHTML file from your eBook that you want to edit.

Now you can edit the file just like you would edit a document in Word. Remove extra and unneeded text, make titles stand out, correct misspellings … anything you want! This is especially helpful if your ePub file was created by converting a PDF as these often have many small errors.

Or, if you’d rather edit the code itself, select the Source tab and edit as you wish.

When you’re done making the changes, make sure to save the file in the same location with the same file name.

Recreate Your Edited ePub eBook

Once you’ve made all the changes you wanted, it’s time to turn this folder of files back into ePub. Make sure you change the name of the folder if it still has the same name as the original ePub or zip file so you don’t mix them up or have trouble with overwriting the old files.

Zip the folder using Windows Explorer or your favorite archival utility. If you are using another archival program, make sure to compress it as a zip folder; other compression methods will render the ePub unreadable by your eReader app.

Now change the file extension again, this time back to .epub. Now you can read your eBook with your changes in your favorite reader program or app on your mobile device.

Conclusion

Whether you need to remove an odd, misplaced character or need to do fine editing, using an HTML editor is a great way to make your ePub eBooks look just like you want. Also, with an editor like KompoZer it’s not even difficult.

Download KompoZer

article source: http://www.howtogeek.com/howto/19268/edit-epub-ebooks-with-your-favorite-html-editor/

So that’s all there is to converting an ePub eBook with KompoZer!

Step 1: Use free software to convert your PDF to ePub
Step 2: Convert the ePub to .zip and unzip
Step 3: Extract the html or xhtml and edit with KompoZer
Step 4: Re-convert the files to ePub

You can then use the eBook and turn it into a mobile app by using free app creation programs like AppGeyser to do so. I use CreateCoolApps. It comes with lots of templates and at 17 dollar a month it’s totally worth it.

Leave a comment

Your email address will not be published. Required fields are marked *

Simple Share Buttons