Blog Archives
A fix for formatting problems with Amazon’s Look Inside function
Today’s helpful hint is for any self-pubbing author who’s had problems with the “Look Inside” function in Amazon completely screwing up your formatting and possibly losing you sales. You see, I checked out Lady of Thorns yesterday and scared the cats with my screaming when I discovered that the preview’s formatting was completely fouled up. I proceeded to check all the rest of my self-pubbed books and discovered the same freaking problem with ALL OF THEM.
After calming down and doing some research, I learned that the Look Inside function interprets HTML very literally and doesn’t always seem to recognize CSS (nobody knows why), which can result in a screwed-up preview even if the actual ebook looks fine.
But there is a way to fix this on your own! Unfortunately Scrivener won’t let me look at an ebook’s HTML so I downloaded Calibre, which will allow you to edit the ebook’s HTML. I added Lady of Thorns in EPUB format to Calibre’s library, then right clicked on it and selected “Edit Book”. That opened up an editing app with a list of all the text pages in the book and their individual CSS style sheets. Ignore the style sheets and focus on the text pages that appear in the Look Inside function (note: a page will be called something like bodyx.xhtml instead of the page name, so just start at the top of the list and open pages until you find the ones you want). Double-click on a page to open it in the HTML editor.
A brief explanation of HTML code: the following code <p>text here</p> indicates that all the text between <p> and </p> (in this case, “text here”) should form a single paragraph. Now look at your page’s HTML code. If a paragraph is primarily something like <p> class=”p1″><br></p>, it’s just a space between paragraphs. Ignore it. But if a paragraph contains text that is screwed up in the preview, replace the paragraph’s <p class=”X”> code (just this first part — you can leave the </p> part alone) with the following:
BODY TEXT
Regular body text to be centered with no indentation: <p style=”margin: 0.0px 0.0px 0.0px 0.0px; text-align: center; text-indent: 0.0px; font-size: 100%”>
Example:
Cautiously, Kel lowered his hand and opened one eye, then the other. Then blinked. Then drooled just the tiniest bit. Because in front of him stood a tall, muscular, absolutely freaking gorgeous man with caramel skin and the abs of a porn star, wearing a linen kirtle and one of the most spectacular scapulars Kel had ever seen.
Regular body text to be left-aligned with no indentation: <p style=”margin: 0.0px 0.0px 0.0px 0.0px; text-align: left; text-indent: 0.0px; font-size: 100%”>
Example:
Cautiously, Kel lowered his hand and opened one eye, then the other. Then blinked. Then drooled just the tiniest bit. Because in front of him stood a tall, muscular, absolutely freaking gorgeous man with caramel skin and the abs of a porn star, wearing a linen kirtle and one of the most spectacular scapulars Kel had ever seen.
Regular body text to be left-aligned with a first line indentation: <p style=”margin: 0.0px 0.0px 0.0px 0.0px; text-align: left; text-indent: 1.5em; font-size: 100%”>
Example:
Cautiously, Kel lowered his hand and opened one eye, then the other. Then blinked. Then drooled just the tiniest bit. Because in front of him stood a tall, muscular, absolutely freaking gorgeous man with caramel skin and the abs of a porn star, wearing a linen kirtle and one of the most spectacular scapulars Kel had ever seen.
Regular body text to be justified with no indentation: <p style=”margin: 0.0px 0.0px 0.0px 0.0px; text-align: justify; text-indent: 0.0px; font-size: 100%”>
Example:
Cautiously, Kel lowered his hand and opened one eye, then the other. Then blinked. Then drooled just the tiniest bit. Because in front of him stood a tall, muscular, absolutely freaking gorgeous man with caramel skin and the abs of a porn star, wearing a linen kirtle and one of the most spectacular scapulars Kel had ever seen.
Regular body text to be justified with a first line indentation: <p style=”margin: 0.0px 0.0px 0.0px 0.0px; text-align: justify; text-indent: 1.5em; font-size: 100%”>
Example:
Cautiously, Kel lowered his hand and opened one eye, then the other. Then blinked. Then drooled just the tiniest bit. Because in front of him stood a tall, muscular, absolutely freaking gorgeous man with caramel skin and the abs of a porn star, wearing a linen kirtle and one of the most spectacular scapulars Kel had ever seen.
HEADERS
Depending on which app you used to create your ebook, your headers (the larger size text used for chapter or page names) will either be indicated with <h1>text</h1> or with <p>text</p>. The following are meant to be used with <p>text</p> headers. To use them with a <h1>text</h1> header, replace the p with h1.
If you want to center a header: <p style=”margin: 0.0px 0.0px 0.0px 0.0px; text-align: center; text-indent: 0.0px; font-size: 133%”>
Example:
KEL MAKES A MISTAKE
If you want to left-align a header: <p style=”margin: 0.0px 0.0px 0.0px 0.0px; text-align: left; text-indent: 0.0px; font-size: 133%”>
Example:
KEL MAKES A MISTAKE
If you want to right-align a header: <p style=”margin: 0.0px 0.0px 0.0px 0.0px; text-align: right; text-indent: 0.0px; font-size: 133%”>
Example:
KEL MAKES A MISTAKE
Note: you don’t have to do this to the entire book, just the pages that show up in the preview. This is usually your front matter (Table of Contents, Title Page, Copyright, Dedication, Acknowlegements) and part of your first chapter. Save your edits and upload the revised ebook file to Amazon. Et voila — the actual ebook looks the same, but now “Look Inside” recognizes the HTML and generates a properly formatted preview.
IMPORTANT NOTE: Depending on when you upload your corrected ebook file, you may not see the changes immediately in Look Inside. Don’t panic! I fixed Lady of Thorns and uploaded it on Wednesday evening, and by Thursday everything on Look Inside was fine. I then did the rest to my other books on Thursday, uploaded them … and on Friday morning they all still had jacked up Look Inside previews. When I contacted Amazon about this, they said that it takes seven days for new/updated book files to appear on Look Inside and to wait a week then check again. Since the preview for Lady of Thorns was fine by Thursday morning, I translated this to mean, “We usually run a batch process every Wednesday night. Check Thursday morning and all your previews should look fine.” In any case, if your preview formatting issues haven’t gone away after you’ve uploaded the corrected file, wait a week, then check again.
And if this makes you want to cry because you don’t DO HTML, dammit, ping me and I’ll help you out.