Uploaded file permissions

dkleehammer - September 19, 2008 - 18:06
Project:Image Upload
Version:6.x-1.0
Component:Code
Category:bug report
Priority:normal
Assigned:Unassigned
Status:postponed (maintainer needs more info)
Description

While testing out the module, I created new content and uploaded some images, but once they were uploaded, I could only see the thumbnails, not the full size images. I did some more research and noticed that the permissions were incorrect.

Here's the permissions for the thumbnail:
-rw-r--r-- 1 nobody nobody 7.2K Sep 19 14:03 i-stress-test_thumbnail.gif

Here's the large version permissions:
--w----r-T 1 nobody nobody 99K Sep 19 14:03 i-stress-test.gif

Also, if it's possible, can you have the image upload module create a new directory under the files directory called 'image_upload', this would really help keep everything in it's place!

Thanks!

#1

dkleehammer - September 19, 2008 - 18:09

I found the problem:

image_upload.module line 170:
chmod($file->filepath, 644); // BUGFIX: force the image to be readable.

PHP chmod needs this to be an octal number ( 0644 ) instead of ( 644 ).

dk

#2

tincorad - September 30, 2008 - 17:16

Thanks!
I was having the same problem, :)

#3

dkleehammer - September 30, 2008 - 19:15

No problem. ;)

#4

bojanz - January 7, 2009 - 13:03

Good thinking dkleehammer! Will release an updated version.

#5

bojanz - January 7, 2009 - 13:03
Status:active» fixed

#6

zet - January 16, 2009 - 22:27

6.x-1.2 sholud have fixed this bug ? I have the latest version but image uploads don't appear. Also , after installing image upload all images from the image module ( that i was previously using ) have disapeared from display .

!?

#7

zet - January 16, 2009 - 22:32
Status:fixed» active

as soon as i disable the image upload module the images from image module they apear back. are those 2 modules in conflict ?

#8

bojanz - February 2, 2009 - 00:49
Status:active» postponed (maintainer needs more info)

I haven't used the image module so I'm not sure, but they shouldn't be, because image_upload is based on the upload module, which is pretty standard stuff. Maybe there's a bug there somewhere...

Will look into it, let me know if you have any more information.

#9

suffering drupal - April 18, 2009 - 00:24

Exactly the same problem here, no new thumbnails or images show up and existing images disappear.
Names are (still) there though and the whole structure seems to stay in place, it just won't show images...
After deactivating all images return, both old ones as the new uploaded ones...
It's like a switch: for upload turn blind, then switch module off an you can see again.... ?¿?
The 0644 thing already show up correctly in the code.

 
 

Drupal is a registered trademark of Dries Buytaert.