Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Calibre > Related Tools

Notices

Reply
 
Thread Tools Search this Thread
Old 06-29-2011, 10:22 AM   #106
chaley
Grand Sorcerer
chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.
 
Posts: 11,734
Karma: 6690881
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
Quote:
Originally Posted by ldolse View Post
Looks like the simpler thing to do would be to figure out why Calbre isn't automatically opening/importing filetypes associated with it and leave things as is with the browser. I'll open a bug on this point.
If/when you want to build an import plugin for a container holding format(s), OPF, and cover, I will be happy to add that to my server.
chaley is offline   Reply With Quote
Old 07-07-2011, 11:28 AM   #107
DiapDealer
Grand Sorcerer
DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.
 
DiapDealer's Avatar
 
Posts: 27,546
Karma: 193191846
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
I wanted to say thanks for sharing this project. I've been wanting to experiment with it and finally got a chance to do so this morning. It's a pretty straightforward setup and it's working great.

For the record... I'm not using Apache at all. I'm using Nginx with PHP running as a FastCGI service (utilizing APC's opcode cache). It's blindingly fast on a very modest server. Thanks again.
DiapDealer is offline   Reply With Quote
Advert
Old 07-07-2011, 01:12 PM   #108
chaley
Grand Sorcerer
chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.
 
Posts: 11,734
Karma: 6690881
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
Quote:
Originally Posted by DiapDealer View Post
For the record... I'm not using Apache at all. I'm using Nginx with PHP running as a FastCGI service (utilizing APC's opcode cache). It's blindingly fast on a very modest server. Thanks again.
Thanks for the thanks, and even more thanks for confirming that it doesn't require Apache or IIS. I wasn't sure if it needed to run as a web server module, and you have answered that question.

Last edited by chaley; 07-07-2011 at 04:10 PM. Reason: Fix name of IIS
chaley is offline   Reply With Quote
Old 07-07-2011, 03:14 PM   #109
Gomez
Junior Member
Gomez began at the beginning.
 
Posts: 6
Karma: 10
Join Date: Jan 2011
Device: Kindle 3
I installed it today and wanna thank too! Nice work!

I use it on my home server with apache/ssl. My libary is on this server and i share it with smb. Good setup for me, i am happy!

Now i browse on my kindle through my library and choose books for my vacation.

Thanks,
Gomez
Gomez is offline   Reply With Quote
Old 07-07-2011, 04:29 PM   #110
DiapDealer
Grand Sorcerer
DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.
 
DiapDealer's Avatar
 
Posts: 27,546
Karma: 193191846
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
I have a problem downloading the books to my Kindle over 3G. I have a Kindle2 with the older browser so I'm wondering if that may have something to do with it? (Yet I have no trouble downloading books directly to my K2 from Calibre's content server over 3G)

Anyway... when using Chrome or Firefox on a Windows Vista PC and on an Ubuntu 10.10 PC, I have no trouble downloading the books. However, when I use the K2's browser, it only seems to download a 16Kb (or thereabouts) fragment that won't open properly. There's no error when downloading... only when trying to open the ebook after downloading.

I may have spoken too soon about my nginx + FastCGI setup. I'm seeing some php errors that are barking about undefined variables and undefined indexes (in files in the smarty_template_c folder). I am using the latest Smarty Templates 3.0.x... has that been tested or do I need to back-rev to an older version?

Everything seems to work fine on the front-end. Just the back-end errors and the Kindle download issue that I can see.
DiapDealer is offline   Reply With Quote
Advert
Old 07-07-2011, 04:42 PM   #111
chaley
Grand Sorcerer
chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.
 
Posts: 11,734
Karma: 6690881
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
Quote:
Originally Posted by DiapDealer View Post
Anyway... when using Chrome or Firefox on a Windows Vista PC and on an Ubuntu 10.10 PC, I have no trouble downloading the books. However, when I use the K2's browser, it only seems to download a 16Kb (or thereabouts) fragment that won't open properly. There's no error when downloading... only when trying to open the ebook after downloading.
If you have sites that work, could you capture the HTTP headers and post them? It could be that I am not supplying all the headers that the K2 wants, or that the headers I am supplying aren't exactly in the format it wants.

It could also be that the K2 wants smaller packets. Today I read, then write, as much as PHP will let me. This could turn into very large logical packets at the TCP level. Perhaps the K2 prefers packets smaller than X, which is also something that I could arrange if I know what X is (16 KB?).
Quote:
I may have spoken too soon about my nginx + FastCGI setup. I'm seeing some php errors that are barking about undefined variables and undefined indexes (in files in the smarty_template_c folder). I am using the latest Smarty Templates 3.0.x... has that been tested or do I need to back-rev to an older version?
I have tested and used only Smarty V2.6. I have no idea if Smarty V3 works.

If you can back-rev to a 2.X version and see if that fixes things, that would be helpful. If I get some time in the next days, I will upgrade to smarty V3 and see what breaks.
chaley is offline   Reply With Quote
Old 07-08-2011, 12:00 AM   #112
DiapDealer
Grand Sorcerer
DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.
 
DiapDealer's Avatar
 
Posts: 27,546
Karma: 193191846
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
Quote:
If you have sites that work, could you capture the HTTP headers and post them?
Do you have a good way to capture headers on the Kindle? That's not something I've tried but it would definitely help the debugging process.

Anyway, I think I narrowed my problem down to the embedded session authentication. Once I disabled authentication (in the config_local.php file), I was able to download books to the Kindle just fine. So I just set up authentication in the web server conf and everything is golden.

That may be related to PHP being run as FastCGI vs Module. I was getting weird permission errors in my server logs until I turned off the embedded authentication. Now I'm not getting any errors.

On a side note... sometime in the twenty minutes or so that my website was wide open for testing purposes, google started crawling my library. I couldn't pay that spider to crawl my websites any other time.
DiapDealer is offline   Reply With Quote
Old 07-08-2011, 02:20 AM   #113
chaley
Grand Sorcerer
chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.
 
Posts: 11,734
Karma: 6690881
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
Quote:
Originally Posted by DiapDealer View Post
Do you have a good way to capture headers on the Kindle? That's not something I've tried but it would definitely help the debugging process.
Absolutely no clue.
Quote:
Anyway, I think I narrowed my problem down to the embedded session authentication. Once I disabled authentication (in the config_local.php file), I was able to download books to the Kindle just fine. So I just set up authentication in the web server conf and everything is golden.

That may be related to PHP being run as FastCGI vs Module. I was getting weird permission errors in my server logs until I turned off the embedded authentication. Now I'm not getting any errors.
Session management was one thing I was/am concerned about when running under flavors of CGI. That said, it must be working if you can search and sort, so I am confused.

I purposely didn't use HTTP authentication to avoid problems with devices that don't handle it well. As far as the kindle is concerned, login is just another page with some form elements on it.

Does your PHP setup use cookies for session management, or does it use query strings and URL rewriting to pass the session token? If the latter, then there might be a problem with the kindle not passing the query string back when doing a download. This would cause the server to go into a login cycle, certainly preventing the download. I can see this happening if the kindle is being smart, noticing the extension on the URL, and doing something special.

Another thought, and one that is embarrassing. When someone logs in, the utility function dprint is called to log the event. This is the only place that dprint is used for a non-exceptional condition. For historical reasons (my debugging), dprint does a check on PHP_OS, and if it isn't "linux", it writes the log line to C:/php_errors.txt. I can imagine this causing some errors and, even worse, write something to the HTTP stream. The latter would prevent writing the headers needed for downloads to succeed, explaining the problem you see. Try commenting out the body of dprint (utilities.php, at the end) and see if the weird errors and/or the kindle problem go away.
Quote:
On a side note... sometime in the twenty minutes or so that my website was wide open for testing purposes, google started crawling my library. I couldn't pay that spider to crawl my websites any other time.
The street view van was also just outside...
chaley is offline   Reply With Quote
Old 07-08-2011, 07:32 AM   #114
auskento
Junior Member
auskento began at the beginning.
 
Posts: 1
Karma: 10
Join Date: Jul 2011
Device: Kindle
I have got this up and running, but I can't get the filtering to work quite the way I want.

On the home page, i only want to see Titles, Authors, Series

I am using the following fields_not_to_dispaly

Code:
$config['fields_not_to_display'] = array('formats', 'identifiers', 'publisher', 'rating', 'tags');
But when I do, i get the following error

Code:
Notice: Undefined index: rating in /websites/calibre/db.php on line 372
Warning: Invalid argument supplied for foreach() in /websites/calibre/db.php on line 372
Notice: Undefined index: rating in /websites/calibre/db.php on line 372
Warning: Invalid argument supplied for foreach() in /websites/calibre/db.php on line 372
And the following shows up in the list

Titles, Authors, Series, Formats (even with formats listed, it gets shunted to the end)

I am also using a search filter to only display a particular type of file format from the library.
auskento is offline   Reply With Quote
Old 07-08-2011, 09:27 AM   #115
chaley
Grand Sorcerer
chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.
 
Posts: 11,734
Karma: 6690881
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
Quote:
Originally Posted by auskento View Post
I have got this up and running, but I can't get the filtering to work quite the way I want.

On the home page, i only want to see Titles, Authors, Series

I am using the following fields_not_to_dispaly

Code:
$config['fields_not_to_display'] = array('formats', 'identifiers', 'publisher', 'rating', 'tags');
But when I do, i get the following error

Code:
Notice: Undefined index: rating in /websites/calibre/db.php on line 372
Warning: Invalid argument supplied for foreach() in /websites/calibre/db.php on line 372
Notice: Undefined index: rating in /websites/calibre/db.php on line 372
Warning: Invalid argument supplied for foreach() in /websites/calibre/db.php on line 372
And the following shows up in the list

Titles, Authors, Series, Formats (even with formats listed, it gets shunted to the end)

I am also using a search filter to only display a particular type of file format from the library.
Ooops.

Ratings and formats use special code outside the main category loop, and I forgot to apply the display check. I will releae a fixed version this weekend.
chaley is offline   Reply With Quote
Old 07-08-2011, 10:54 AM   #116
DiapDealer
Grand Sorcerer
DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.
 
DiapDealer's Avatar
 
Posts: 27,546
Karma: 193191846
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
Quote:
Originally Posted by chaley View Post
Does your PHP setup use cookies for session management, or does it use query strings and URL rewriting to pass the session token? If the latter, then there might be a problem with the kindle not passing the query string back when doing a download. This would cause the server to go into a login cycle, certainly preventing the download. I can see this happening if the kindle is being smart, noticing the extension on the URL, and doing something special.
My PHP is set up to use cookies.

Quote:
Originally Posted by chaley View Post
Another thought, and one that is embarrassing. When someone logs in, the utility function dprint is called to log the event. This is the only place that dprint is used for a non-exceptional condition. For historical reasons (my debugging), dprint does a check on PHP_OS, and if it isn't "linux", it writes the log line to C:/php_errors.txt. I can imagine this causing some errors and, even worse, write something to the HTTP stream. The latter would prevent writing the headers needed for downloads to succeed, explaining the problem you see. Try commenting out the body of dprint (utilities.php, at the end) and see if the weird errors and/or the kindle problem go away.
Commenting out the body of the dprint function made no noticeable difference.

However, after tweaking some of the FastCGI parameters for my Nginx server... I seem to have everything working fine, now. Including the internal authentication and file downloads (with the dprint function). Bumping up various fastcgi timeouts, buffers, busy buffers, and adjusting the temp file write size seemed to do the trick.

I'll let you know what else I run into.
DiapDealer is offline   Reply With Quote
Old 07-10-2011, 11:16 AM   #117
chaley
Grand Sorcerer
chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.
 
Posts: 11,734
Karma: 6690881
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
Release 0.2.6 available

Release 0.2.6 is available at http://charles.the-haleys.org/calibre/

Note: if you are using fields_to_display or fields_not_to_display, you must ensure that the values in the list are all lower case.

Change log:
Spoiler:
78 charles <> 2011-07-10 {REL 0.2.6}
Release 0.2.6

77 charles <> 2011-07-10
Update version number

76 charles <> 2011-07-10
Fix user categories not showing their name

75 charles <> 2011-07-10
Fix problem with case matching when specifying the fields to/not to display. Force them to be lowercase.

74 charles <> 2011-07-10
Fix problems arising when either rating or formats is not shown
chaley is offline   Reply With Quote
Old 08-12-2011, 04:35 PM   #118
eVrajka
Junior Member
eVrajka began at the beginning.
 
Posts: 4
Karma: 10
Join Date: Aug 2011
Location: Russia, Saint-Petersburg
Device: none
Thanks for you work, it's very important project.
I tried to customize the web interface , but unfortunately I can not find opportunities to do so. I did some sketches, tell me please how I can implement it.
Spoiler:




Thank you.
eVrajka is offline   Reply With Quote
Old 08-13-2011, 11:00 PM   #119
Pope Viper
Member
Pope Viper began at the beginning.
 
Pope Viper's Avatar
 
Posts: 21
Karma: 10
Join Date: Jun 2011
Device: none
I'd appreciate some help, if someone who is running this under a IIS 7.5 would be willing to post their config_local.php, I would appreciate it, I seem to be having difficulties getting it figured out.

Thanks!
Pope Viper is offline   Reply With Quote
Old 08-14-2011, 04:38 AM   #120
chaley
Grand Sorcerer
chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.
 
Posts: 11,734
Karma: 6690881
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
Quote:
Originally Posted by eVrajka View Post
Thanks for you work, it's very important project.
I tried to customize the web interface , but unfortunately I can not find opportunities to do so. I did some sketches, tell me please how I can implement it.
You would change the smarty template for the category or categories that you want to appear as a table.

Getting the information for the currently selected book is probably best done using AJAX, but that will be a significant change. AJAX isn't used anywhere in the server. To add it, you will need to add a new module that supplies metadata for specific books, and then write the javascript that uses the module.

Good luck with your development.
chaley is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Calibre Command Line usage with PHP artoros Related Tools 13 07-01-2010 09:57 AM
Web Content Server mezme Calibre 7 01-08-2010 09:59 PM
Calibre web server on MAC I cant get to work.. any help appreciated. stustaff Calibre 5 01-06-2010 06:05 PM
Calibre - web server problems eclpmb Calibre 9 11-28-2008 02:04 PM


All times are GMT -4. The time now is 05:22 PM.


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