Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Category Images NOT Uploading


Guest

Recommended Posts

I'm baffled again...I have imported my categories from an earlier version, they are showing the description and category image.

 

I added a new category using the admin, uploaded the picture, viewed the 'preview', everything seems fine. Go back to the same category and I get "IMAGE DOES NOT EXIST".

 

If I add the image name directly to the database it works fine.

 

I'm using "categories.php,v 1.4 2002/09/08 20:23:47 wilt Exp $" that was included in the Loaded Snapshot from Ian.

Link to comment
Share on other sites

I found that to solve this I change all reference to the copy function to the move_uploaded_file function.

 

Then it uploads directly via the admin section.

The image is then instantly displayed.

 

CC.

Link to comment
Share on other sites

Hi CC!

 

When you say remove all reference to the copy function to the move_uploaded_file function. Are you meaning the references for the small, medium, and large images too?

 

The only one I'm having trouble with is the category header image.

Link to comment
Share on other sites

No what I mean is in categories you have this line:

 

copy($categories_image, $image_location);

 

I changed this to:

 

move_uploaded_file($categories_image, $image_location);

 

And now OSC uploads the exact image I want there and then.

It will work for Category headers, images etc...

That one particular line is for the category images, but you can also do the same for the products image.

If yours is working ok at this time for the product image I wouldn't be to worried about changing that part.

 

Let me kow if it works for you.

 

CC.

 

BTW - This will dump all images in the catalog/images folder and wont go into subfolders.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...