You can create your own HTML templates and use them within the eBook Starter program. Creating a Template Folder Your first step will be to create a template folder for your new template. Although you can name the folder whatever you'd like, your template name must be followed by .files. Your template folder should look something like this: The 'template' text in the example above may be replaced by the text of your choice. Your new folder should be placed with the rest of the eBook Starter templates here:
C:\Program Files\eBook Starter\Templates Creating Your Page Folders Your next step will be to create a folder within your template.files folder for each page your template will contain. Each page must have its own folder that contains all the files for that particular page, including images and CSS files. Although you can name the folders whatever you'd like, your folder name must be followed by .files. In addition, your folder name must have the same name as your page name. For example, if your file is called index.htm, your folder should be called, index.files. Your template folders might look something like this: Template Image In addition to your template.files folder containing pages and page folders, you will also need a screen shot image of your template. This image must be 200*200 pixels in size and must be in BMP format. It will be displayed within the template wizard. Description Text File And finally, you will need to create a text file called, description. The description file contains a simple sentence describing the template. This description will be displayed within the little window beneath the template screen shot within the eBook Starter program. Creating an EBT File Your next step will be to create a file with the same name as your template folder, except with an EBT extension. In this example, the file will be called: template.ebt This file may be created within a text editor and should be placed in the same directory as your template.files folder. However, make certain you don't place the file within the template.files folder, as your template will not function properly. Your file should look something like this: XML Coding The EBT file should be written in XML and be formatted something like this:
The above XML coding will specify exactly how your template should be displayed. In this example, the template will look like this within the 'Files Window' of eBook Starter: Your template can be displayed however you'd like as long as you follow the basic formatting guidelines. XML Template Chart
Files Window The above example is just that -- an example. You can format your templates however you'd like. For additional examples, you can look at the current eBook Starter templates here: C:\Program Files\eBook Starter\Templates Designing Your Template Pages Although you can design your pages however you'd like, you must include a special META tag between your HEAD tags and create specific 'Content' areas so that your pages can be edited within the eBook Starter editor. Your META tag should look like this:
Your content areas should look something like this:
HTML Template Chart
Displaying Images within Your Template If your template will be displaying any images, the image code within your HTML must look something like this:
The code is a macro and will be automatically replaced by the template's folder name. The image text indicated in red should be changed to the name of your image. Displaying a Table of Contents If your template will be displaying a Table of Contents, place the following code within the HTML of your TOC page like this:
The code is a macro and will be automatically replaced by the titles of your pages that link to each corresponding page. Opening External Links within Your eBook in a New Window If you would like the external links within your eBook to open in a new window, you will need to include the following JavaScript (indicated in bold) between the <HEAD> and </HEAD> tags of your HTML document:
This script will enable your external links to open within a new window and not within your ebook.
<< Go back