![]() |
#1 |
Junior Member
![]() Posts: 3
Karma: 10
Join Date: Sep 2010
Device: ipod
|
HTML Metadata
I am trying to convert HTML into books.
I would like to know how all the metadata gets automatically imported. I was directed here: https://www.mobileread.com/forums/sho...44&postcount=9 It lists what metadata is supported, but it seems uncompleted & does not explicitly state what calibre field it imports too. For example, is the Tags filed here? I am specifically wondering what HTML tags would end up specifying: 1. Cover Image 2. Custom Meta Data 3. Tag Data Thanks Brendan |
![]() |
![]() |
![]() |
#2 |
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 45,144
Karma: 27110892
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
If you want complete metadata control, use an OPF file that references your html file and or use the ebook-meta tool to set metadata after the conversion
|
![]() |
![]() |
Advert | |
|
![]() |
#3 |
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 4,004
Karma: 177841
Join Date: Dec 2009
Device: WinMo: IPAQ; Android: HTC HD2, Archos 7o; Java:Gravity T
|
|
![]() |
![]() |
![]() |
#4 |
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 45,144
Karma: 27110892
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
No, Charles and I are working on that right now.
|
![]() |
![]() |
![]() |
#5 |
ZCD BombShel
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 4,793
Karma: 8293322
Join Date: Jan 2009
Location: The Frozen North (aka Illinois, USA)
Device: iPad, STB Kindle Oasis
|
Y'all simply amaze me. I keep finding new features I didn't know Calibre had, and then I keep reading this thread and finding out what you're planning to make it even better. Some of it I'll freely admit is over my head, but I'm still lost in wonder and awe.
|
![]() |
![]() |
Advert | |
|
![]() |
#6 |
Junior Member
![]() Posts: 3
Karma: 10
Join Date: Sep 2010
Device: ipod
|
I really like the OPF idea. When I am creating the OPF, would I only need to create the <metadata> portion or would I also need to generate the <manifest> section?
When you say I would reference it, how would I do this? Through a HTML meta tag? Or do you mean that the OPF be dragged into calabre for processing & the HTML index page be referenced for calabre to link up to the HTML data? I pulled the OPF metadata off one book I am trying to "bind". Also, I don't see the cover file referenced here. It is specified in titlepage.xhtml though. Can I specify a cover image in teh OPF? Can you give an example? I am trying to turn a book archive website that hosts books in HTML over so an ePUB can be made of all of them. I am thinking the most streamlined way i can think of is to have a separate "book" made by the server and zipped up. The zip could the be dragged into calabre, or perhaps unzipped and the index (or some other file) dragged into calabre and boom! the ePUB is created. No manually specifying meta data or format or such. Thanks for all your help. <?xml version="1.0" encoding="UTF-8"?> <package xmlns="http://www.idpf.org/2007/opf" version="2.0" unique-identifier="uuid_id"> <metadata xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns ![]() <dc:creator opf:role="aut" opf:file-as="Brendan, Ferguson">Brendan Ferguson</dc:creator> <dc ![]() ![]() <meta name="calibre:series_index" content="1"/> <meta name="calibre:rating" content="0"/> <dc:language>en</dc:language> <meta name="calibre:timestamp" content="2010-09-07 03:11:09.117767+00:00"/> <dc:title opf:file-as="Leading Thoughts">Leading Thoughts</dc:title> <meta name="cover" content="cover"/> <dc:date>1973-09-06 00:00:00-04:00</dc:date> <dc:contributor opf:role="bkp">calibre (0.7.17) [http://calibre-ebook.com]</dc:contributor> <dc:identifier id="uuid_id" opf:scheme="uuid">3a6d021e-5018-48b1-b4b2-04d1323bc7b5</dc:identifier> <dc:identifier opf:scheme="ISBN"></dc:identifier> <dc:description></dc:description> </metadata> |
![]() |
![]() |
![]() |
#7 |
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 45,144
Karma: 27110892
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
add a html file to calibre, it wil be auto converted into a zip that alsocontains an OPF. Open the zip and look at the opf it will give you an idea of what to do.
You need <metaata> for metadata, a <manifest> to list the html files and a <spine> to specify their order. |
![]() |
![]() |
![]() |
#8 |
Junior Member
![]() Posts: 3
Karma: 10
Join Date: Sep 2010
Device: ipod
|
So what you are saying then, is that its not practile to generate a OPF via Server Side script as one WOULD need to specify <manifest> etc. which the script would not nessacaraly know about.
In other words, its not possible to reference a OPF with primarily metadata content to be included in the process of creating a epub from HTML. Is this what you are saying? |
![]() |
![]() |
![]() |
#9 |
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 45,144
Karma: 27110892
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
No, that's not what I'm saying. I'm saying generate the OPF file in your script. there's nothing mysterious about a <manifest>
|
![]() |
![]() |
![]() |
#10 |
Connoisseur
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 73
Karma: 11638
Join Date: Aug 2010
Location: Spain
Device: iPad, Kindle Paperwhite, Kobo Libra 2
|
Would that add support for the dc:language tag in the "Edit metadata" form?
So far it looks that calibre does not retrieve this tag nor does allow to set it. I have added this tag to all my books so I'd love if it becomes actually useful ![]() |
![]() |
![]() |
![]() |
#11 |
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 45,144
Karma: 27110892
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
No calibre sets language based on whatever the interface language is. Support for book specific languages is on the todo list
|
![]() |
![]() |
![]() |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Recognition of author and title from html files/reading metadata from a seperate file | Lethe | Calibre | 5 | 04-03-2010 08:35 AM |
"metadata" (toc) in HTML documents | pedz | Calibre | 8 | 03-30-2010 09:23 PM |
(X)HTML Metadata | rogue_ronin | Calibre | 4 | 12-31-2009 10:01 PM |
metadata out of Html | horseman | Calibre | 0 | 08-04-2009 08:34 AM |
Wide margins in html to epub; font size mngmt; PDF metadata | dementrio | Calibre | 2 | 08-01-2009 01:33 AM |