Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Calibre

Notices

Reply
 
Thread Tools Search this Thread
Old 09-10-2016, 04:40 PM   #1
CodeVisio
Junior Member
CodeVisio began at the beginning.
 
Posts: 5
Karma: 10
Join Date: Sep 2016
Device: none
Adding a simple html file (and its folder) as a book

Hi,

I'd like to add a simple html file and its folder to Calibre as I can do with other book formats and _without any_ additional manipulation/filtering/transformations/ etc Calibre normally does.
So clicking on it ,I can see it on my default browser or Calibre's browser.

I noticed instead that when I add a single html file, Calibre produces a zip file.
I could disable the plugin responsible for that. But still, Calibre rename the original html file, adding the author (that in my case is Unknown). In that case I cannot see it well on a browser.

Any idea how can I add a simple html file and its foder to Calibre?

Thank you
CodeVisio is offline   Reply With Quote
Old 09-10-2016, 06:31 PM   #2
BetterRed
null operator (he/him)
BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.
 
Posts: 21,717
Karma: 29711016
Join Date: Mar 2012
Location: Sydney Australia
Device: none
@CodeVisio - Calibre determines the folder and file names in the library folder, see ==>> Want to change folder structure or file names in the Calibre library?

And that's not going to change.

Calibre uses its library database is its primary source of information. The author and book folders are only there as a place to store format files, cover images, and metadata backup files. The fact that they are deriived from author names and titles is arbitrary, they could have been database table row numbers.

If you're mainly interested in converting your HTML to an ebook format such as ePub or a Kindle format, you could use of the command line program ebook-convert and not bother with the library manager, see Command Line Interface

BR
BetterRed is offline   Reply With Quote
Advert
Old 09-10-2016, 06:43 PM   #3
skb
Evangelist
skb ought to be getting tired of karma fortunes by now.skb ought to be getting tired of karma fortunes by now.skb ought to be getting tired of karma fortunes by now.skb ought to be getting tired of karma fortunes by now.skb ought to be getting tired of karma fortunes by now.skb ought to be getting tired of karma fortunes by now.skb ought to be getting tired of karma fortunes by now.skb ought to be getting tired of karma fortunes by now.skb ought to be getting tired of karma fortunes by now.skb ought to be getting tired of karma fortunes by now.skb ought to be getting tired of karma fortunes by now.
 
skb's Avatar
 
Posts: 401
Karma: 1597305
Join Date: Mar 2010
Device: Ipod G4, MacOS 10.12, Calibre, Pocketbook Touch HD 3
Hi!

I think you can turn it off by going to Preferences > Plugins and select "File Type Plugins".

Select the plugin "HTML to Zip" and disable it.

However...I'm not sure whatever ramifications, if any, this action causes. But I just tried it with my Calibre library and I imported a HTML file and it stayed a HTML file The only thing it changed was the filename (to title_author.html) but it did put it in its own directory.

I hope that helps (a bit).

cheers

Edited: Oh, wait. You did all that. Sorry. Ignore me...

Last edited by skb; 09-10-2016 at 06:45 PM. Reason: I don't read very well :)
skb is offline   Reply With Quote
Old 09-11-2016, 03:48 AM   #4
itimpi
Wizard
itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.
 
Posts: 4,553
Karma: 950151
Join Date: Nov 2008
Device: Sony PRS-950, iphone/ipad (Marvin/iBooks/QuickReader)
One huge downside to disabling the importing of HTML files and storing them as ZIP files is that you lose any external files referred to by the HTML file such as style sheets, images (covers), etc. It also only works if there is a single HTML file, not a series of linked ones for different sections of the eBook. The default Calibre import of HTML parses the HTML during the import and adds these to the zip file it creates. Since a large proportion of eBooks tend to have these additional files it is definitely something to consider when making a choice to store just the HTML file. You also lose the compression of the HTML (which can be anything up to 90% reduction in size for HTML) although I suspect most people are less concerned about that.
itimpi is offline   Reply With Quote
Old 09-11-2016, 11:51 AM   #5
DaltonST
Deviser
DaltonST ought to be getting tired of karma fortunes by now.DaltonST ought to be getting tired of karma fortunes by now.DaltonST ought to be getting tired of karma fortunes by now.DaltonST ought to be getting tired of karma fortunes by now.DaltonST ought to be getting tired of karma fortunes by now.DaltonST ought to be getting tired of karma fortunes by now.DaltonST ought to be getting tired of karma fortunes by now.DaltonST ought to be getting tired of karma fortunes by now.DaltonST ought to be getting tired of karma fortunes by now.DaltonST ought to be getting tired of karma fortunes by now.DaltonST ought to be getting tired of karma fortunes by now.
 
DaltonST's Avatar
 
Posts: 2,265
Karma: 2090983
Join Date: Aug 2013
Location: Texas
Device: none
If you truly want it as-is, use the MFI Media File Importer in Other Binary mode to add a 7zip .7z file of everything you mentioned. Click that Format in the Details Pane, then click the main html file to view it.

DaltonST
DaltonST is offline   Reply With Quote
Advert
Old 09-11-2016, 04:51 PM   #6
CodeVisio
Junior Member
CodeVisio began at the beginning.
 
Posts: 5
Karma: 10
Join Date: Sep 2016
Device: none
@All

Thanks a lot. I think I've explained it bad but probably what I want to do
is conceptually wrong.

I saved locally a web page (an article I want to read later). As such I have the html file along with a folder containing the web page's css, images etc. If I load this locally web page from a web browser I can see the it more or less as the original. So far so good.

Instead of having all thousands of web pages saved here and there I thought I could store them inside the my Calibre's library.
So I added one of those web pages inside my calibre's library.
1) The first result I got with Calibre is a zip file inside my library folder under the author's name. At this point if I click on my web page inside the big list of Calibre what happens is that the default zip/unzip program is invoked and the zip file is opened inside it.
I don't want 1).

2) So I discovered the concept of plugins inside Calibre. I disabled then the one that converts that html to zip and looked at the result and added the the html to my library again. At this point if I click on webpage from the big list on Calibre the web page is shown through a Calibre's viewer. But unfortunately the web page is displayed wrong because all of images, css etc are not stored inside my library.
I don't want also 2).

My intention and expectation was that Calibre could store the html and its relative folder of css, images etc, directly inside my Calibre's library. So I could click on the that article from the big list on Calibre and have the web page displayed correctly inside my default web browser.

Is that possible?

let me know if it's not clear.

Thanks
CodeVisio is offline   Reply With Quote
Old 09-11-2016, 05:30 PM   #7
BetterRed
null operator (he/him)
BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.
 
Posts: 21,717
Karma: 29711016
Join Date: Mar 2012
Location: Sydney Australia
Device: none
As you've seen when you add an html file to a calibre library the software will create a zip that includes the html and the files it references, such as images. I suggest you convert the ZIP to ePub and view the ePub. Or in the Preferences->Behaviour->User Viewer for list, check the entry for ZIP, that does a conversion to ePub on the fly.

Also take a look at GrabMyBooks and dotEPUB, they can produce ebook formats directly from the web page. I think I've see posts at MR describing how to add the ePubs directly into a calibre library.

FWIW - I use Evernote for the sort of thing your doing, occasionally I export a web clipping from Evernote to HTML which I import into calibre and convert to ePUB.

BR

Last edited by BetterRed; 09-11-2016 at 05:37 PM.
BetterRed is offline   Reply With Quote
Old 09-11-2016, 05:44 PM   #8
CodeVisio
Junior Member
CodeVisio began at the beginning.
 
Posts: 5
Karma: 10
Join Date: Sep 2016
Device: none
Thanks BetterRed. It works perfectly.
CodeVisio is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Adding files to a book's folder? JuanDescole Library Management 5 01-24-2013 09:20 PM
Adding a file in the Misc folder roger64 Sigil 3 11-08-2012 03:57 AM
Calibre hangs on adding large HTML file kongzifan Conversion 2 12-10-2011 05:05 AM
problem adding complex html file space4 Library Management 1 03-05-2011 01:45 PM
Problem with converting very simple HTML file with table frabjous Calibre 3 09-18-2009 02:36 PM


All times are GMT -4. The time now is 09:40 PM.


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