ZuZu Posted September 28, 2009 Share Posted September 28, 2009 Most images in the img folder uploaded through the PS backoffice had permission 600. I could not change or download them to my pc. The owner of the file was 'apache'. In order to make a backup of my img folder I had asked my host to make me owner so that I could change the permissions of the files.Now none of the images show in either my backoffice or store front. Even when I upload the ones that I do have backupped again they don't appear..... just the red X-es indicating that the images isn't there. Please help... what can I do?See pic of backoffice and you can imagine what my store lookes like... (i closed it)Thanks! Link to comment Share on other sites More sharing options...
radders Posted September 28, 2009 Share Posted September 28, 2009 If you are the owner and the permissions are set at 600 then I don't think php would be able to read them. Usually php runs as user 'nobody' from what I have heard. You don't need anything more restrictive than 644 for images.Several suggestions for the longer term (any one should work):1) get your host to change the ownership of the files as from time to time as needed2) get your host to ensure that ftp and php are in the same group3) run php in such a way that you are the owner (suPHP)4) backup using cPanel instead of ftphth Link to comment Share on other sites More sharing options...
codegrunt Posted September 29, 2009 Share Posted September 29, 2009 As radders says, you need to change the permissions on the files so that Apache (the web server) can read them. Most FTP clients should let you do this fairly easily or if you have shell access you can do the same thing much more quickly using find:cd [put prestahop directory name here]find . -type f \( -name \.jpg -o -name \.gif -o -name \.png \) -exec chmod 644 {} \;If you are going to do this with an FTP program, I suggest Filezilla:http://filezilla-project.org/If you go with Filezilla, you need to do two things. . .1. set up and apply a filename filter that only shows images (.jpg, .png, .gif) This is done via the "View->Filename Filters" menu. This will make it so you are only changing permissions on images and not other important files or directories.2. perform a recursive chmod on the root Prestashop directoryThis is done by right clicking on the directory you want to change permissions under and choosing "file permissions".Cheers Link to comment Share on other sites More sharing options...
ZuZu Posted September 29, 2009 Author Share Posted September 29, 2009 Talked to the host. They claimed to have done nothing, but suddenly while they were 'looking' it was solved.... :-)Thanks for your replies!! Link to comment Share on other sites More sharing options...
first1 Posted September 29, 2009 Share Posted September 29, 2009 Lol, then they have done nothing! Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now