This article was first published in the July 2011 edition of PC Update, the magazine of the Melbourne PC User Group. The article refers to a Kindle-formatted file of this article, which can be Download here: Create your own book on a Kindle
Let us assume you have bought a Kindle, the best selling ebook reader from Amazon. In addition to some free classic novels and a couple of best sellers you may have bought. you would rather like to add the first draft of your own Great Australian Novel, or, more likely, the report you have been preparing for your local service club.
I looked at several methods and my first attempt used a page layout program I am used to, InDesign, which recently included abilities to output to ePub files that can be converted for the Kindle and other ebook readers.
That worked well, but it was complex and I am not about to tell MelbPC members that they should go out and buy programs in the four-figure price range.
Can it be done for nothing? The answer is Yes.
Firstly, what is a Kindle book file? As supplied by Amazon they usually have an .azw extension and appears to be a proprietary format though similar to the published .mobi format. which is the same as the Palm format with the .prc extension. Both of these are recognised by the Kindle.
All these formats are based on XML, eXtensible Markup Language, which brings us to the best known such language which is HTML, Hypertext Markup Language, as used by the vast majority of web sites. In fact, a restricted form of HTML, with a small number of extra tags, is as good a means as any to use for creating an ebook.
There is a very limited range of HTML tags which can be used for formatting a book to read on a Kindle. If you have ever formatted a web page then this will come as no problem to you.
The main ones you have to play with are the set of heading tags: <h1> to <h6> getting progressively smaller (and their associated closing tags </h1> etc; <hr /> for a horizontal rule; <i> and </i> for italics (or you can use the <em> tags for "emphasis"; <b> and /b> for bold (or use the <strong> set); and <blockquote> and close with </blockquote> for a long quotation inset from the left margin.
As well you can use a limited number of CSS (cascading style sheet) commands either in your HTML file or in a separate file that is linked as it would be for a web page and include that in the same folder. If you are used to working with CSS do not try anything far from the most common tags.
Among a very few specific mobi tags is <mbp:pagebreak /> for a page break (suprisingly this seems to be forgotten by many book converters -- a new page for a new chapter does make the whole production look professional). Note that there is a space before the ending slash.
A PDF of the tags which can be used is available from http://kindleformatting.com/ but here is a simple template which might get you going:
<html>
<head>
<title>My first Kindle book</title>
</head>
<body>
<h2>My first Kindle book</h2>
<h4>By firstname lastname</h4>
<p> </p>
<p>Based on a template published in PC Update, the magazine of the Melbourne PC User Group</p>
<mpb:pagebreak />
<h3>Chapter one</h3>
<p>Here goes all the text you need in as many paragraphs as you need.</p>
<mpb:pagebreak />
<h3>Chapter two</h3>
<p>Here goes all the text you need in as many paragraphs as you need. </p>
</body>
</html>
This is simple enough to edit in Notepad without getting lost in the tags, but you may find it simpler to use a Text Editor, most of which put the tags in a different colour to the text so that you can easily tell the difference. I currently use Gizmo but I have also used NotePads++ from http://notepad-plus-plus.org/ which is also free.
Calibre at http://calibre-ebook.com/ is a program which will manage an ebook collection for one or more ebook readers and will convert between formats as needed within the limits imposed by Digital Rights Management. But Calibre offers many options, often hidden from obvious control, so while it is a program I would recommend, it is easier for the beginner in this field (which was me a matter of a couple of months ago) to use simpler and more specific converters.
For this article I used the free Mobipocket Creator from http://www.mobipocket.com which is a French company that was bought by Amazon in 2005. It is simple to use in that you create a new blank publication and then drag in the HTML file and any required graphics files (plus the CSS file if you are using one), and then click on the Build icon. We will ignore the optional steps to add a cover page and a table of contents. Try these when you have achieved your first success. There is a clear Help file.
Once you have you file, you can then connect your Kindle and drag the completed file, which will have a .prc extension to the documents folder of the Kindle, ready to read.
This article is available as a PRC (Mobi) file at the link shown at the head of this blog post and is available as a Zip file with the complete article as an ebook ready to view on your Kindle and as an HTML file so that you may examine the original code.


Recent Comments