When I set an additional image size 'large' in addition to the default 'thumbnail' and 'preview' I get an error message after inserting an image. The error says:
the selected file <em>/home/peter_n/public_html/drupaltest/files</em> could not be copied
In addition to the error message, a file of 0 bytes is created in my files/images directory called files. If I try and insert a new image, the same message appears, but the new file is called files_0.
If I use only the default thumbnail and profile, there is no error message.
I'm using Drupal 4.7.0 beta 3 and Image module from cvs.
Comments
Comment #1
grohk commentedI am experiencing this problem even when the extra size is not set. It looks to me like the image module is unable to move the images out of the temp folder and instead creates new images with _0 appended to the end of the filename. This is more than a minor bug since a warning is displayed on every upload, and am setting it as such.
Comment #2
yched commentedThis is because the sizes stored in the 'image_sizes' variable include the lines that are left blank in the 'sizes' form of the image settings page.
_image_get_sizes currently retrives the content of this variable 'as is', thus including dumb "empty" sizes (no label, no diemnsions...)
This patch modifies _image_get_sizes so that it filters the 'image_sizes' variable and returns only the valid sizes.
NB : There is a "ready to be commited" patch here, involving the exact same lines,
dealing with images.module not functionning with locale.
Comment #3
veelo commentedThis patch seems to work for me.
Bastiaan.
Comment #4
grohk commentedWorks for me too +1
Comment #5
peter_n commentedand me too.
Comment #6
walkah commentedcommitted thanks.
Comment #7
(not verified) commented