Forums / Setting Up Categories, Products, Attributes / Attribute Images - Some Show, Some Don't

Attribute Images - Some Show, Some Don't

Started by dianne on 23 Mar 2015, 12:14 AM · Views: 658

Results 1 to 3 of 3
23 Mar 2015, 12:14 AM
#1
dianne avatar

dianne

Zen Follower

Join Date:
May 2007
Location:
Virginia, USA
Posts:
102
Plugin Contributions:
0

Attribute Images - Some Show, Some Don't

Scratching my head on this one...

I am providing full details in case the problem is within the actions I took. If you want to jump to the question, it's in blue below.

I used Easy Populate 4.0.24 to upload the names of the attribute images and attach the image to the value. I started with the "Detailed Products Attributes" spreadsheet that included columns for (among other things)

  • the product option name
  • the product option value
  • the attributes image for the option value

My spreadsheet contained all of the above information for over 800 values. I uploaded the spreadsheet but none of the images showed on the product page in the storefront.

In looking at the spreadsheet, I realized that perhaps the problem was that the image name should have included the folder name since the default folder is "main" and these are in the "attributes" folder.

So, I changed a few to test this by adding the prefix "attributes/" to a few, so that the image name now showed as "attributes/image_name.jpg". I only did a few like this to see if that would make the image show up.

It worked!

So, using the same spreadsheet, I changed 50 more and uploaded those to see the attribute images on the product page, except this time the images were **not **showing.

I can't figure out why the attribute image is not showing.

I checked for spelling, capitalization and extra spaces. I checked to be sure the images are uploaded to the correct directory; I even used the Attribute Controller to navigate to one of the attributes, click "edit" and scroll down to see if the image was showing there (where ordinarily you would be using your browser to upload the image manually).

The image NAME was shown there correctly, right under the browse button (attribute/image_name.jpg) BUT the Attribute Image Directory drop-down showed "Main Directory" when it should have shown "attributes" for the directory where the image is located.

I tried changing the drop-down to "attributes" and clicking to update, but that did not change the directory shown in the drop-down menu or make the image appear.

However, if I used the browse button to **manually **upload the image from my computer (leaving the default "yes" on override existing image - "no" on delete image from product), and chose the attributes directory from the drop-down, **that **made the image show up on the product page.


Viewing the edit screen after the upload still shows the image name as "attributes/image_name.jpg" and now the Attribute Image Directory is correctly shown as "attributes".

My Question:

How and where can I change the system to recognize that the image is in the attributes folder and not the main directory **without **having to upload them all manually via that browse button on the edit screen. There are over 800...way to many for manual changes.

On the spreadsheet, the images are listed as being in the attributes folder ("attributes/image_name.jpg"), but when you view the edit screen for the attribute, while the image name is correctly shown, the drop down menu has "Main Directory" as the folder. How can I change that without having to re-upload all the images manually.

I can't find anywhere to correct the directory.

FWIW
The gold dot that is supposed to turn "green" when the image is attached, is still gold, even for all the images that do show correctly in the storefront.

Thanks for anything you can share.

23 Mar 2015, 1:13 PM
#2
twitchtoo avatar

twitchtoo

Totally Zenned

Join Date:
Apr 2007
Location:
Ontario, Canada
Posts:
1,733
Plugin Contributions:
14

Re: Attribute Images - Some Show, Some Don't

If you are certain all of the images are in the same folder, you can run an** SQL script** to update the beginning of each of the data fields where the products - products_image, products_attributes - attributes_image are stored.

Alternately, you can run a similar script using an MS Excel macro/script on your spreadsheet. This becomes a one click wonder... and it's a bit safer because there's an undo button and you can see the results before uploading to your live site.

As for the icon colours, I would wonder if there's a switch that needs to be included in the table that didn't get included in your export... and needs to be turned on when there's an image. This too can be solved by an SQL statement to turn the switch on when it sees a value in the attributes_image field.

Twitch.
https://www.twitchtoo.com Do you work for free? Please donate.
June 7.2026 - NOW AVAILABLE - Twitch Base8 - Obsidian

23 Mar 2015, 1:39 PM
#3
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Attribute Images - Some Show, Some Don't

If you want them in the /images/attributes directory and are importing the information, use:
attributes/filename.extension

When there is an image on the Attribute it will be yellow (or gold) ...

NOTE: missing attribute images do not have any special indicator, as they are not tested for at this time ...

NOTE: The red and green icons are used for when there is a download filename on the attribute to indicate if the file is on the server (green icon) or not (red icon) ...

Linda McGrath
If you have to think ... you haven't been zenned ...

**Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!**

Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
Officially PayPal-Certified! Just click here

Try our Zen Cart Recommended Services - Hosting, Payment and more ...
Signup for our Announcements Forums to stay up to date on important changes and updates!