How do I fix this error I get when I try to upload a site logo?

> warning: move_uploaded_file() [function.move-uploaded-file]: SAFE MODE
> Restriction in effect. The script whose uid is 10002 is not allowed
> to access /tmp/tmp_JVpRXE owned by uid 48 in
> /var/www/vhosts/website2.net/httpdocs/includes/file.inc on line
> 240.

I changed the permissions but it did not help

Comments

MandrakeTheMagician’s picture

Just ask your hosting manager to remove the safe mode, I did it and the safe mode has been removed in a second, now everything is ok.

stinhambo’s picture

What about people that can't get SAFE MODE removed?

My host asked me if Drupal specifies it's own path. They have specified a temp directory in the Virtual Host but I am still getting the errors.

I am using 4.7 by the way.

As If’s picture

make sure you are specifying an actual, accessible folder for the temp folder at admin/settings/file-system. Usually the File System Path is files (which must be chmod 777) and the Temporary Directory is files/temp <-NOTE this is DRUPAL's temporary upload folder, not PHP's, and also must be 777. These are both relative to the Drupal install folder.

-------------------------------------------
Interactive Worlds and Immersive Obsessions
http://www.asifproductions.com

-------------------------------------------
Interactive Worlds and Immersive Obsessions
http://www.asifproductions.com

stinhambo’s picture

Thank you As If that worked brilliantly :)

Vietyank’s picture

I've done as above.
files/tmp is 777 apache:apache
files is 777 apache:apache

Not sure what ownership should be. I ended up turning safe mode off but might like to turn it back on if workaround works