Zen Cart Logo
Forums / General Questions / Images not working as expected

Images not working as expected

Views: 1,709

Results 1 to 15 of 15
29 Apr 2014, 7:12 PM
#1
bikerstuff avatar

bikerstuff

New Zenner

Join Date:
Apr 2014
Posts:
80
Plugin Contributions:
0

Images not working as expected

I've tried to search on this but not found anything yet.

First my large product image is not working correctly.
The image is 800X800 and it works fine for smaller images as Zencart scales it down for thumbs and item pages. The problem is when going to view the full size image Zencart pops it up in a full screen and the bottom of the image is cut off! Normally there would be a scroll bar to the right to move the image to view the lower part, but none it there!
Sometimes other sites you would just click and hold mouse to move the image up, but that does not work either.

So if a customer goes to look at the large image of the item the only thing they will see is about the top 3/4 of it.
I have viewed the distributors site and 2 competitors and they also are using the 800x800 images and on there sites I do get the scroll bar on the right to move it up and down to view full image, just not on my site!
Is there a setting or switch I need to change I have not found yet so it does that like it should?

Also, I can not find it now, but I did read I should be able to use a base name like myvest.jpg and it should find all variants of that base name and use the images for multiple images.
That does not seem to be working for me.
I do have settings to use multiple images enabled, I forget the specific name right now or where they are, it was in the info I read but cannot find again now.

So I have items named such as myvestSM and myvestXXL, of course the SM and XXL is the size of the vest. The way my distributor does it and how I have to order the items.
My images are myvest_800.jpg and myvestBK_800.jpg for example and of course the BK is the image of the back of the vest.
If I try to add just base name myvest.jpg both images should be found and used from what I have read, but nothing is! So my items show with NO picture at all.

I do allot of searching and reading, and have for awhile even before joining the forum.
I am a total Newbie, but not lazy and I do try to find info before asking.
Everything is rather confusing of course being new to everything and though this is a good forum it does not all work as I am used to so also trying to figure out how to find things I don't even know what to call them for search terms really. LOL

Sometimes I can be a bit slow, I finally setup a printer on this computer last night so now when I find things I need I can print them out! I try to bookmark things also, but I guess I forgot a few things as I can't find them now there either.

29 Apr 2014, 7:21 PM
#2
bikerstuff avatar

bikerstuff

New Zenner

Join Date:
Apr 2014
Posts:
80
Plugin Contributions:
0

Re: Images not working as expected

Oh, and to make things a bit more confusing on my end I use more than one computer to work with.
So if wife is on this one I use my laptop. That adds to my confusion some as I may have bookmarks on either computer, and to copy and paste info to a file it could be on either, not always on the one I am on. LOL

1 May 2014, 12:27 PM
#3
lat9 avatar

lat9

Administrator

Join Date:
Sep 2009
Location:
Stuart, FL
Posts:
14,102
Plugin Contributions:
56

Re: Images not working as expected

Bikerstuff:

My images are myvest_800.jpg and myvestBK_800.jpg for example and of course the BK is the image of the back of the vest.
If I try to add just base name myvest.jpg both images should be found and used from what I have read, but nothing is! So my items show with NO picture at all.
Assuming that the base image that you've recorded for this product is myvest_800.jpg, then the back-of-vest image should be named myvest_800_BK.jpg (or something like that). Zen Cart takes your product's image name (myvest_800) and looks for all images that match the template myvest_800*.jpg to use as additional images for the product.

1 May 2014, 3:16 PM
#4
stevesh avatar

stevesh

Black Belt

Join Date:
Feb 2005
Location:
Lansing, Michigan USA
Posts:
19,793
Plugin Contributions:
2

Re: Images not working as expected

1 May 2014, 5:03 PM
#5
bikerstuff avatar

bikerstuff

New Zenner

Join Date:
Apr 2014
Posts:
80
Plugin Contributions:
0

Re: Images not working as expected

In the tutorial it shows what I tried to do pretty much as I did it.

Original Image: fred.jpg

All of these are considered additional images because they contain the base image name PROVIDED you are in the /images directory:

fredabc.jpg
fred_73b2.jpg
fred_01.jpg
fred_02.jpg
freddy.jpg
fredrick.jpg

In the example the only reason for the _01 etc.. was to provide a sort order, which I don't need.

SO, fred.jpg should find
fredabc.jpg
freddy.jpg
fredrick.jpg

Because all those begin with fred as the base. The extra abc dy rick in those examples I think is the same as my bk side etc.. in my files

I think what I did was the exact same thing just different names, but did not work for me.
All images in the /images folder, no problem there. Setting to use additional images set.

Base myvest.jpg should then find
myvest_800.jpg
myvestBK_800.jpg
myvestside_800.jpg

NOTHING was added, not even the plain myvest_800.jpg though. The _800 is the size of the image of course and all images have that. I only used/uploaded the 800 size, though I have same images in _200 _400 _600 sizes but have not uploaded those to site and won't need them.

The BASE name of all images is the same as the item number, so I was in the item edit page and copy/pasted the item number into the IMAGE box and added .jpg to make my base.
So Item # myvest I entered as a base as myvest.jpg but no image was added/found.
When I entered the full image name myvest_800.jpg then that one image is found and added to the product page.

So it looks like the Zens item page IS looking in the correct /images and I have upload to the correct /images because it can find the image if I use the correct full filename, but it does not find any if I use just the base as tutorial says. All my images are uploaded to same folder so that should not be any problem either, if one can be found then all should be able to be found.

If I could get this working as it should it would make life so much easier. LOL
As my supplier uses item# as the image name, then to make the base name in a CSV file I only need to copy and past the item# column and rename it as V_image (or such) then manually edit and paste .jpg to every item in the new image column. In theory if all is working then when Easyupdate imports that CVS file all images should be working.
That is how I got 1 image per product to add for the ones I did so far, but I had to past in _800.jpg to the item number and that only shows one main image, nothing for back or side view images or any other extras like item boxes etc..

I am learning allot fast, considering I never even tried using things like Zenstore, openoffice, etc.. before and had no clue what a CVS file was a few weeks ago.
Still tons and tons to learn though of course.

1 May 2014, 5:17 PM
#6
bikerstuff avatar

bikerstuff

New Zenner

Join Date:
Apr 2014
Posts:
80
Plugin Contributions:
0

Re: Images not working as expected

stevesh:

The tutorial is here:

http://www.zen-cart.com/content.php?100

Thank you.

I have it bookmarked now!

I went through every page of the tutorials (again) yesterday and book marked allot of things I think I will need so I can find them again later when needed.
I should have bookmarked them before!

1 May 2014, 7:01 PM
#7
bikerstuff avatar

bikerstuff

New Zenner

Join Date:
Apr 2014
Posts:
80
Plugin Contributions:
0

Re: Images not working as expected

Here is a kinda simple idea what I am trying to do using a real product, a flashlight and from the Zencart catagory/product Item page

Products Model: ELANT1

select an existing image file from server, filename: ELANT1.jpg This is the base name for the .jpg image
Nothing is added for the image, preview shows the file-name ELANT1.jpg but no image just blank box.

I use the full name of ELANT1_800.jpg and the image was found and added to the preview page and now in store.

select an existing image file from server, filename: ELANT1_800.jpg
so the image was there and Zen found it when using the full file name, but not if using the basename ELANT1.jpg.
I now have 1 product image online for that item, if there others, say the display box or such it is not added this way.
All images for this item, however many there may be, would start with ELANT1 and end with _800.jpg what is in between the start and end would be BK for Back, box for package, etc...

So as I read tutorial, ELANT1.jpg as the base should find everything beyond the ELANT1 so
ELANT1_800.jpg should have been found and also anything else like.
ELANT1bk_800.jpg
ELANT1box_800.jpg

I know I am missing something but can't figure out what!
I just checked again and I do have the option set to use additional images.

1 May 2014, 8:06 PM
#8
bikerstuff avatar

bikerstuff

New Zenner

Join Date:
Apr 2014
Posts:
80
Plugin Contributions:
0

Re: Images not working as expected

Did I just find my problem?

Note: the base image name is the original image name loaded for the product.

Does that mean the image HAS TO EXIST?
I took that to mean that the name was the name to load, to use as the base name, not that the original image name has to actually exist as a file itself.

So when trying to use myvest.jpg as a base name I have never actually had a plain myvest.jpg file of that name.
Is THAT why it has not been working!

I only tested 3 items, and I think they are working now, so maybe that was my problem?

If it was the problem, maybe for real DUMMIES like me the tutorial could be edited to mention "the file has to exist that is being used as a base". LOL

Well, it opens a whole new can of worms for me as I will have to rename 2500 images or so I guess.

1 May 2014, 9:26 PM
#9
stevesh avatar

stevesh

Black Belt

Join Date:
Feb 2005
Location:
Lansing, Michigan USA
Posts:
19,793
Plugin Contributions:
2

Re: Images not working as expected

I'd guess that was the problem. It may not have occurred to the developers that anyone would want to refer to an image that didn't exist. Also, you need to be careful mixing lower and upper case letters in file and image names. I use all lower case as a rule. ('Course, my old DOS brain also limits file names to eight characters, plus extension.) :laugh:

1 May 2014, 9:46 PM
#10
bikerstuff avatar

bikerstuff

New Zenner

Join Date:
Apr 2014
Posts:
80
Plugin Contributions:
0

Re: Images not working as expected

Yep probably not.
But when you have allot of files that start with abcd and onwards then on my end I would think a search for anything abc would bring up all other files, even if abc did not exist as just abc.

I guess I was thinking of the old search with wild cards type things * and ? so myvest* to bring up all files that begin with myvest, even though exactly myvest would not exist. LOL

Yep, good old DOS days, when we actually had to LEARN to use a computer, not just point and click at stuff!
I forgot most of what I used to be able to do now, I probably could not even change directories any more in DOS 3 . LOL

2 May 2014, 2:03 AM
#11
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
176

Re: Images not working as expected

Yes, the image must be on the server. It can't find or display an image which isn't on the server.

The FAQ article has been updated.

2 May 2014, 8:07 AM
#12
bikerstuff avatar

bikerstuff

New Zenner

Join Date:
Apr 2014
Posts:
80
Plugin Contributions:
0

Re: Images not working as expected

Cools, Thanks

I did have the images I wanted to find on my server though. The part I did wrong was I did not have any image at all using the base name.

Base name myvest.jpg but there is no such file anywhere, it does not exist at all, but I was still expecting all OTHER files to be found using that base name.

I been using EasyUpdate to bulk import items, and once I figure out a few tricks here and there it is working really well for me. Provided I don't make a mistake like I did yesterday!

Question.
If I use the base name (correctly this time LOL ) to add images to my items once, then if I later upload more images will the items just automatically still show the new images?

So I actually make a myvest.jpg image and use that name as a base it will find the images such as myvest2.jpg and myvest3.jpg now. If I later upload myvest4.jpg will it just show up in the item listing, or do I have to do something to add it after I upload it later?
I am thinking it will just be added to the listing just being uploaded later, but thought I should ask to be sure.
You know how I am. LOL

And thanks again everyone for all the help!

2 May 2014, 1:15 PM
#14
mc12345678 avatar

mc12345678

Totally Zenned

Join Date:
Jul 2012
Posts:
16,908
Plugin Contributions:
2

Re: Images not working as expected

Also regarding the renaming of hundreds/thousands ofimages, there are some naming tools (wish I could remember what has been suggested to me) that can go out and modify filenames for you. Ideally you would just have to take the _??? Of your choosing and drop that from all files to get back to having a file thathas the base name desired forthat product. As stevesh suggests/leads to, it may be desirable to have products in directories to minimize the number of files that end up with "duplication".

2 May 2014, 3:14 PM
#15
bikerstuff avatar

bikerstuff

New Zenner

Join Date:
Apr 2014
Posts:
80
Plugin Contributions:
0

Re: Images not working as expected

Thanks,

I will do a search for a rename tool for the files themselves.

I recall there was a way to also get a print to file list of all the files in a directory too, but it has been so long I forget how, if it was a dos command, or if it was a small program. That would help also since all the images are same name as item numbers.
I would have to of course watch close for any errors, but if all the images are there and no extra's in the folder, then in theory I could print the directory to file, copy and paste into the spread sheet, then check that all items and pictures have matching names.
That would save a ton of typing which I am not good at and hours of work since I am so slow. LOL

You can probably tell I am not great at typing with all the errors in my posts, and that I am slow because the 7 minute timer runs out before I am done proof reading so I can't edit to fix the mistakes I typed. LOL