Register Guidelines E-Books Search Today's Posts Mark Forums Read

Go Back   MobileRead Forums > E-Book Software > Calibre > Conversion

Notices

Reply
 
Thread Tools Search this Thread
Old 11-27-2011, 03:13 PM   #1
mvparker79
Junior Member
mvparker79 began at the beginning.
 
Posts: 2
Karma: 16
Join Date: Nov 2011
Device: iPad
Creating My First Cookbook

I think my request is fairly simple, but I'm oblivious to xpath so I don't know what to do.

I'm using Calibre 0.8.23 to convert a cookbook I've compiled over the years in word form. I'm trying to create the table of contents and it wants the xPath expression of each of 3 levels. I have no idea what to put in there. I do know that in the table of contents I want 2 levels. I have each section of the cookbook (meats, poultry, etc) labeled as chapters (Chapter 1: Meats) (Chapter 2: Poultry). Then the name of each recipe is at the top of the following pages in bold. I would like the table of contents to read:

Chapter 1: Meats
Hamburgers
Tacos

Chapter 2: Poultry
Fried Chicken
Chicken Marsala

I'm also having problems with the page breaks. I put a page break after each recipe so they would be on their own page just like a real cookbook. I converted the .doc file to PDF format, but when it converts to ePub, it removes the breaks.

Can anyone tell me how to construct the table of contents and keep the breaks?

Last edited by mvparker79; 11-28-2011 at 11:35 AM.
mvparker79 is offline   Reply With Quote
Old 11-28-2011, 11:19 AM   #2
Starson17
Wizard
Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.
 
Posts: 4,004
Karma: 177841
Join Date: Dec 2009
Device: WinMo: IPAQ; Android: HTC HD2, Archos 7o; Java:Gravity T
Quote:
Originally Posted by mvparker79 View Post
I think my request is fairly simple, but I'm oblivious to xpath so I don't know what to do.

I'm using Calibre 0.8.23 and I'm trying to create the table of contents. It wants the xPath expression each of 3 levels. I have no idea what to put in there. I do know that in the table of contents I want 2 levels. I have each section of the cookbook (meats, poultry, etc) labeled as chapters (Chapter 1: Meats) (Chapter 2: Poultry). Then the name of each recipe is at the top of the following pages in bold. I would like the table of contents to read:

Chapter 1: Meats
Hamburgers
Tacos

Chapter 2: Poultry
Fried Chicken
Chicken Marsala

Can anyone tell me how to do this?
This is the recipe forum. Unfortunately, the term "recipe" used here means computer code that tells calibre how to create an ebook from a website. I've written several recipes (calibre-type) for websites that have recipes (food-type). You're in the wrong forum for food recipes.

I can move your post, but it's not clear if you are creating a book from scratch, or converting an existing book of food recipes.

If you are creating a book, you probably don't want to be in the calibre forums at all. If you are simply converting an ebook, you want to be in the calibre conversion forum, and that's where I'm going to move this thread for you to get more help.
Starson17 is offline   Reply With Quote
Advert
Old 11-28-2011, 11:29 AM   #3
mvparker79
Junior Member
mvparker79 began at the beginning.
 
Posts: 2
Karma: 16
Join Date: Nov 2011
Device: iPad
Sorry everyone. Noob here.
mvparker79 is offline   Reply With Quote
Old 11-28-2011, 11:46 AM   #4
Starson17
Wizard
Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.
 
Posts: 4,004
Karma: 177841
Join Date: Dec 2009
Device: WinMo: IPAQ; Android: HTC HD2, Archos 7o; Java:Gravity T
Quote:
Originally Posted by mvparker79 View Post
Sorry everyone. Noob here.
That's OK. We're just trying to help you and I thought you'd get more help here. So do you already have a book?

I'm tempted to say go to the Sigil forum. I use Sigil to add my TOC and adjust TOC entries for books in my calibre library. You set the header tags h1, h2, h3 for different levels in Sigil, then hit the create TOC button and Sigil builds it for you. You could also do an EPUB to EPUB conversion to do what you want with XPATH, but that tends to be more cryptic for most users.
Starson17 is offline   Reply With Quote
Old 11-28-2011, 02:12 PM   #5
theducks
Well trained by Cats
theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.
 
theducks's Avatar
 
Posts: 29,778
Karma: 54830978
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
I would go the Sigil route;
First, it is WYSIWIG , so it will be easier to see what happens.

Assign heading levels
<h2> for your chapters
<h3> for your recipes

and the TOC will happen (after you click the button) as you show

If you want to keep a Chapter in a single file and still have Page breaks.

assign a class to those H3 tags (in Code View) that contains: page-break-before:always as one of the entries
theducks is online now   Reply With Quote
Advert
Reply

Tags
calibre, xpath

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Cookbook Conversion BenG Sony Reader 5 08-08-2011 07:34 PM
Your favourite cookbook? hallali Reading Recommendations 42 10-14-2009 06:25 PM
The Kindle Cookbook dre95060 Amazon Kindle 0 09-27-2008 10:53 AM
Kitchen Cookbook edbro Sony Reader 9 08-28-2007 10:58 AM


All times are GMT -4. The time now is 07:50 PM.


MobileRead.com is a privately owned, operated and funded community.