thibaud-rohmer / PhotoShow

A free web gallery in PHP with drag-n-drop support
http://www.photoshow-gallery.com
505 stars 152 forks source link

thumbnails not created #283

Open roger21 opened 9 years ago

roger21 commented 9 years ago

hello

well, title says all

i got those kind of errors

ERROR/Provider::image path:generated/Thumbs//pics/tram.jpg does not exist, using photos/pics/tram.jpg, referer: http://192.168.0.5/phs/?t=Adm&a=Set

ERROR/Provider::image path:generated/Thumbs//pics/tram_small.jpg does not exist, using photos/pics/tram.jpg, referer: http://192.168.0.5/phs/?t=Adm&a=Set

and generated/Thumbs/pics only contains .right.xml

i couldn't figured out how to get the debug out of phpthumb so not much more to add

phpThumb.demo.check.php bothered about cache and tmp folder not existing or being writable so i created one writable one, it changed nothing (except phpThumb.demo.check.php got greener)

(i got gd, not imagemagick)

roger21 commented 9 years ago

so it was because i put relative paths to the picture directories in config.php

(it worked for photoshow, but not for php thumb)

relative paths is not an option here (could be specified in the readme.md)

thibaud-rohmer commented 9 years ago

That must depend on the version of phpthumb. My photoshows all use relative paths and I don't have that issue.

Le ven. 5 juin 2015 19:04, roger21 notifications@github.com a écrit :

so it was because i put relative paths to the picture directories in config.php

(it worked for photoshow, but not for php thumb)

relative paths is not an option here (could be specified in the readme.md)

— Reply to this email directly or view it on GitHub https://github.com/thibaud-rohmer/PhotoShow/issues/283#issuecomment-109364701 .

roger21 commented 9 years ago

well, let just say we have the same version to begin with, because that would make no sense, i have the one provided by PhotoShow and i hope that's the one you're working with too

then i just put an error_log in function DebugMessage($message, $file='', $line='') of phpthumb.class.php

error_log("POUET PHPTHUMB -> ".$message.($file ? ' in file "'.(basename($file) ? basename($file) : $file).'"' : '').($line ? ' on line '.$line : '')); // same message as the one created by phpthumb

my relative paths being respectively "photos" and "generated" in the config file and being in the root directory of photoshow (and i get the same results by using "./photos" and "./generated" in the config file)

the error i get (notice the src/phpthumb/ in the path) is:

POUET PHPTHUMB -> RenderToFile() failed because "/var/www/photoshow/src/phpthumb/generated/Thumbs/pics/" is not writable in file "phpthumb.class.php" on line 544, referer: http://192.168.0.5/photoshow/?t=Adm&a=Se

the path given to RenderToFile() by Provider::thumb() being generated/Thumbs//pics/image.png (and ./generated/Thumbs//pics/image.png)

giving absolute paths "/var/www/photoshow/photos" and "/var/www/photoshow/generated" or $_SERVER["DOCUMENT_ROOT"]."/photoshow/photos" and $_SERVER["DOCUMENT_ROOT"]."/photoshow/generated" in the config file solved the issue

so i don't know what you're using as relative paths but from what i got it seems pretty obvious that giving a relative path won't work (at least for the "generated" directory)

en3r0 commented 9 years ago

I believe I am having this same issue. The page loads slowly each time and there is nothing in the Thumbs folder...

trampi commented 9 years ago

I've had the same issue (no thumbnails could be generated), using absolute paths helped.