Zen Cart Logo
Forums / Installing on a Windows Server / Internal Server 500 error on uploaded images ver 1.3.7.1

Internal Server 500 error on uploaded images ver 1.3.7.1

Locked

Views: 2,698

Results 1 to 8 of 8
This thread is locked. New replies are disabled.
9 Jan 2010, 7:20 PM
#1
spaz_tic avatar

spaz_tic

New Zenner

Join Date:
Nov 2009
Posts:
18
Plugin Contributions:
0

Internal Server 500 error on uploaded images ver 1.3.7.1

Weirdest thing I've ever seen...

When I upload images through Zen Cart the picture doesn't show. The rendered code is correct, the image is in the right place on the server and is not corrupted, it just doesn't show.

I did some investigating and found that if I tried to browse to the file directly it threw a 500 error.

So, using my ftp software, I deleted the file then put it in the same folder using FTP and now the image shows. I can't just move it and then put it back. I have to delete it, then send using FTP. But it only works the first time. If I go back and do it again, I then get a 404 error.

I've narrowed this down (I think) to an IIS issue but I don't know where to find the logs or what the next step should be would be most appreciated.

I wouldn't even mind the extra work so much but this is for a client.

TIA

9 Jan 2010, 10:56 PM
#2
absolute avatar

absolute

Totally Zenned

Join Date:
May 2005
Location:
Bath, Somerset
Posts:
1,054
Plugin Contributions:
2

Re: Internal Server 500 error on uploaded images ver 1.3.7.1

What permissions does your IMAGES folder have? What is the permission level of the images? You may find that even though you have WRITE permissions to put the files on the server, you don't then have permissions to check that they are there or indeed read them again. Just set the images directory to 0777 to check if it is a permissions issue.

Absolute

10 Jan 2010, 6:39 AM
#3
spaz_tic avatar

spaz_tic

New Zenner

Join Date:
Nov 2009
Posts:
18
Plugin Contributions:
0

Re: Internal Server 500 error on uploaded images ver 1.3.7.1

I've got read, write and modify on the images folder and all the subfolders.

I think that covers it.

10 Jan 2010, 7:09 AM
#4
spaz_tic avatar

spaz_tic

New Zenner

Join Date:
Nov 2009
Posts:
18
Plugin Contributions:
0

Re: Internal Server 500 error on uploaded images ver 1.3.7.1

Although....

When the images are uploaded, a new user, IIS_IUSR is created on the folder that only has "special" permissions. If I edit that to include read, the imgae shows up.

Ok, now what do I do??

Absolute:

What permissions does your IMAGES folder have? What is the permission level of the images? You may find that even though you have WRITE permissions to put the files on the server, you don't then have permissions to check that they are there or indeed read them again. Just set the images directory to 0777 to check if it is a permissions issue.

Absolute

10 Jan 2010, 2:28 PM
#5
absolute avatar

absolute

Totally Zenned

Join Date:
May 2005
Location:
Bath, Somerset
Posts:
1,054
Plugin Contributions:
2

Re: Internal Server 500 error on uploaded images ver 1.3.7.1

It sounds like the user that is writing the files to the server is set up so that they can't read by default. Your best bet is to approach your host, and explain the problem, and ask them to either change the default permissions, or change who is running the script.

Absolute

10 Jan 2010, 9:01 PM
#6
spaz_tic avatar

spaz_tic

New Zenner

Join Date:
Nov 2009
Posts:
18
Plugin Contributions:
0

Re: Internal Server 500 error on uploaded images ver 1.3.7.1

Does Zen Cart upload images into a temp directory?

I did some more looking about this type of error and saw that a similar problem exists in uploading WordPress images. And it just so happens that this is a combo WordPress/Zen Cart install.

In those articles, the consensus was that the temp folder that WordPress uses to upload images needs to have the same permissions as the folder the image winds up in. They also suggest that you use a new folder rather than a windows system folder and reflect the change in php.ini.

I tried all that and it's still not working but I thought maybe Zen Cart has a different folder it uploads images into?

Thanks for all the help!

10 Jan 2010, 9:23 PM
#7
spaz_tic avatar

spaz_tic

New Zenner

Join Date:
Nov 2009
Posts:
18
Plugin Contributions:
0

Re: Internal Server 500 error on uploaded images ver 1.3.7.1

Hey, it worked!

On a whim I went back and restarted the server. I guess the changes to php.ini required a restart.

Anyway, it's working now. Thanks for the help!

11 Jan 2010, 11:31 AM
#8
absolute avatar

absolute

Totally Zenned

Join Date:
May 2005
Location:
Bath, Somerset
Posts:
1,054
Plugin Contributions:
2

Re: Internal Server 500 error on uploaded images ver 1.3.7.1

No problem - thank you for posting the solution and an update. It's always nice to see threads closed off with a working solution, just in case someone in the future has the same problem and stumbles across your thread.

Absolute