Zen Cart Logo
Forums / All Other Contributions/Addons / Image Handler 4 (for v1.5.x) Support Thread

Image Handler 4 (for v1.5.x) Support Thread

Views: 343,313

Results 1,041 to 1,060 of 1,691
17 Mar 2014, 11:56 AM
#1041
aquaessential avatar

aquaessential

New Zenner

Join Date:
Mar 2005
Location:
England
Posts:
66
Plugin Contributions:
0

Image Handler 4 (for v1.5.x) Support Thread

I've got a large database of images, and save all images in the appropriate name for SEO purposes. Only snag is that image handler removes the name I save them as and changes it to something specific and non related. This is of course useless to google (but convenient to me as it converts 1 image to 3 different sized images).

I would dearly love google to use all 1700 of my images and increase traffic to my site.

Does anyone know of a way around this so that the names are saved as the proper name as opposed to what image handler does to them?

DivaVocals recommended to re-write the part of the IH4 code that manages the image cache file naming. My coder can't seem to find the function responsible for renaming thumbs.

Can DivaVocals advise?

Thanks!

17 Mar 2014, 12:45 PM
#1042
divavocals avatar

divavocals

Totally Zenned

Join Date:
Jan 2007
Location:
Los Angeles, California, United States
Posts:
10,011
Plugin Contributions:
3

Re: Image Handler 4 (for v1.5.x) Support Thread

aquaessential:

I've got a large database of images, and save all images in the appropriate name for SEO purposes. Only snag is that image handler removes the name I save them as and changes it to something specific and non related. This is of course useless to google (but convenient to me as it converts 1 image to 3 different sized images).

I would dearly love google to use all 1700 of my images and increase traffic to my site.

Does anyone know of a way around this so that the names are saved as the proper name as opposed to what image handler does to them?

DivaVocals recommended to re-write the part of the IH4 code that manages the image cache file naming. My coder can't seem to find the function responsible for renaming thumbs.

Can DivaVocals advise?

Thanks!

Nope.. It IS a re-write of a core part of IH's core code.. But off the top of my head, I don't know which files are impacted.. I've never looked into this deep enough because this part of the code really isn't "broken"..

BTW.. Google could CARE LESS what your images are named.. Google will still find and index your site's images regardless of what they are named..

17 Mar 2014, 4:11 PM
#1043
joepixel avatar

joepixel

New Zenner

Join Date:
May 2008
Location:
orlando, florida
Posts:
28
Plugin Contributions:
0

Re: Image Handler 4 (for v1.5.x) Support Thread

Hi,

Has anyone had an issue where the last product image is duplicated when adding additional product images. I have a client that has this issue fairly consistently. The image size is not large (which I see can be an issue). I can't find any errors associated with this. And, I've not been able to duplicate this myself. But, it does happen to my client and I can't figure out why. And, I don't see anyone else here having the same issue. Any ideas?

Zen Cart version 1.5.1
Image Handler 4

Thanks!

18 Mar 2014, 3:33 AM
#1044
divavocals avatar

divavocals

Totally Zenned

Join Date:
Jan 2007
Location:
Los Angeles, California, United States
Posts:
10,011
Plugin Contributions:
3

Re: Image Handler 4 (for v1.5.x) Support Thread

joepixel:

Hi,

Has anyone had an issue where the last product image is duplicated when adding additional product images. I have a client that has this issue fairly consistently. The image size is not large (which I see can be an issue). I can't find any errors associated with this. And, I've not been able to duplicate this myself. But, it does happen to my client and I can't figure out why. And, I don't see anyone else here having the same issue. Any ideas?

Zen Cart version 1.5.1
Image Handler 4

Thanks!

Not an IH4 issue (otherwise others would report this issue..) This probably is an image naming issue and there is a section of the readme that points in the right direct to fix it.

21 Mar 2014, 1:48 PM
#1045
kitcorsa avatar

kitcorsa

Totally Zenned

Join Date:
Feb 2007
Posts:
1,724
Plugin Contributions:
0

Re: Image Handler 4 (for v1.5.x) Support Thread

sorted png and jpg not allowed

21 Mar 2014, 3:02 PM
#1046
divavocals avatar

divavocals

Totally Zenned

Join Date:
Jan 2007
Location:
Los Angeles, California, United States
Posts:
10,011
Plugin Contributions:
3

Re: Image Handler 4 (for v1.5.x) Support Thread

kitcorsa:

sorted png and jpg not allowed

let me guess.. not an IH4 issue??:smile:

27 Mar 2014, 12:26 PM
#1047
kitcorsa avatar

kitcorsa

Totally Zenned

Join Date:
Feb 2007
Posts:
1,724
Plugin Contributions:
0

Re: Image Handler 4 (for v1.5.x) Support Thread

couldn't figure out why additional items were coming up RED in the admin and could see the problem in the instructions. Found the solution on a different website and then found the LIMITATIONS of IH4 in the instructions.

27 Mar 2014, 2:12 PM
#1048
divavocals avatar

divavocals

Totally Zenned

Join Date:
Jan 2007
Location:
Los Angeles, California, United States
Posts:
10,011
Plugin Contributions:
3

Re: Image Handler 4 (for v1.5.x) Support Thread

kitcorsa:

couldn't figure out why additional items were coming up RED in the admin and could see the problem in the instructions. Found the solution on a different website and then found the LIMITATIONS of IH4 in the instructions.

Why don't you share the DETAILS of the issue and the solution.. Might help others..

28 Mar 2014, 1:41 PM
#1049
grantopt avatar

grantopt

New Zenner

Join Date:
May 2012
Posts:
36
Plugin Contributions:
0

Re: Image Handler 4 (for v1.5.x) Support Thread

How does the background color work. For my small images, I selected the settings of "png" and background color of "'-transparent-". But its still rendering as white. I wanted to make it match the odd and even rows of the product listing page like the IH4 example shows. Currently all my images are jpg. If I understand correctly, imagemagick would convert them on the fly to png? Or would I have to initially made my pictures with png transparent backgrounds as the default images and then it would work. If that is the case I will live with a white background on all images as it would be tedious to get them converted to pngs.

28 Mar 2014, 1:46 PM
#1050
divavocals avatar

divavocals

Totally Zenned

Join Date:
Jan 2007
Location:
Los Angeles, California, United States
Posts:
10,011
Plugin Contributions:
3

Re: Image Handler 4 (for v1.5.x) Support Thread

grantopt:

How does the background color work. For my small images, I selected the settings of "png" and background color of "'-transparent-". But its still rendering as white. I wanted to make it match the odd and even rows of the product listing page like the IH4 example shows. Currently all my images are jpg. If I understand correctly, imagemagick would convert them on the fly to png? Or would I have to initially made my pictures with png transparent backgrounds as the default images and then it would work. If that is the case I will live with a white background on all images as it would be tedious to get them converted to pngs.Explained n the readme..

29 Mar 2014, 12:58 AM
#1051
grantopt avatar

grantopt

New Zenner

Join Date:
May 2012
Posts:
36
Plugin Contributions:
0

Re: Image Handler 4 (for v1.5.x) Support Thread

DivaVocals:

Explained n the readme..

Read it again. I know that Imagemagick can convert jpg images to png transparency with scripts. But I don't know if image handler has that functionality to make use of imagemagick scripts. Is their a place I can add scripts inside the files to convert the jpgs background to transparency. This seems the only way I can use the background color settings.

This is what I tested this morning.

  1. I have 2 pictures, 1 in jpg with white background and 1 in png with alpha transparency
  2. Uploaded each of them to separate product listings
  3. Changed settings in IH4 to use 255:0:0 (red) background color and use filetype png
  4. On viewing the catalog side, only the product with the default png image shows a red background. But the default jpg (png IH4 converted) still has the white background.

When viewing the image source, it does show that the jpg was converted to a png in the bmz cache folder.

So basically what I am asking does IH4 only change the filetype? And what I suspect is that IH4 does not make use of scripts to convert backgrounds to alpha transparent. The readme does not cover this as it gives examples of uploading a jpg in the above example and using other filetypes for resize images. And then moves to the topic of background colors. Unless it is to be assumed that you have to start with a gif or png with a transparent background then I understand how it is covered in the readme.

29 Mar 2014, 1:51 AM
#1052
gilby avatar

gilby

Totally Zenned

Join Date:
Aug 2005
Location:
Vic, Oz
Posts:
1,816
Plugin Contributions:
0

Re: Image Handler 4 (for v1.5.x) Support Thread

From the readme
"If you want to keep the transparency of an uploaded image, you need to set the background color value to transparent."

This implies to me that you need to have a transparent background to start with.

Having used various photo tools to remove backgrounds and then clean up what is left manually.
I doubt there is a photo tool that can do this automagically and give a satisfactory result.

So I cannot see that IH would be set up or able to do this either.

29 Mar 2014, 5:26 AM
#1053
divavocals avatar

divavocals

Totally Zenned

Join Date:
Jan 2007
Location:
Los Angeles, California, United States
Posts:
10,011
Plugin Contributions:
3

Re: Image Handler 4 (for v1.5.x) Support Thread

grantopt:

The readme does not cover this as it gives examples of uploading a jpg in the above example and using other filetypes for resize images. And then moves to the topic of background colors. Unless it is to be assumed that you have to start with a gif or png with a transparent background then I understand how it is covered in the readme.true.. However, your original question didn't give me any indication what you were asking after either.. (it was a bit broad.. hence why I pushed you back to the readme..)

gilby:

From the readme
"If you want to keep the transparency of an uploaded image, you need to set the background color value to transparent."

This implies to me that you need to have a transparent background to start with.

Having used various photo tools to remove backgrounds and then clean up what is left manually.
I doubt there is a photo tool that can do this automagically and give a satisfactory result.

So I cannot see that IH would be set up or able to do this either.Exactly.. IH4 can convert filetype (JPG --> PNG), but adding a transparent background to a converted image?? No.. IH4 doesn't do this.. To see the background color, start with an image with a transparent background and the background color in the settings will show through..

30 Mar 2014, 3:41 AM
#1054
k1ra avatar

k1ra

New Zenner

Join Date:
Jul 2013
Posts:
57
Plugin Contributions:
0

Re: Image Handler 4 (for v1.5.x) Support Thread

I've got an odd issue. I just upgraded IH4 to the latest version, 4.3.2, and now my image swap does not work. I did not seem to have this problem with IH 4.2.

Image that was just replaced and image swap is not swapping correct image:

r o s e c i t y v i n t a g e [dot] com/index.php?main_page=product_info&cPath=1_5&products_id=384

Image that for some reason is not being resized, and working correctly

r o s e c i t y v i n t a g e [dot] com/index.php?main_page=product_info&cPath=1_5&products_id=74

My modified code in modules/additional_images.php is in red and TEXT_CLICK_TO_ENLARGE has been removed:

    $thumb_regular = zen_image($base_image, $products_name, MEDIUM_IMAGE_WIDTH, MEDIUM_IMAGE_HEIGHT);
    $large_link = zen_href_link(FILENAME_POPUP_IMAGE_ADDITIONAL, 'pID=' . $_GET['products_id'] . '&pic=' . $i . '&products_image_large_additional=' . $products_image_large);

    // Link Preparation:
    $script_link = '<script language="javascript" type="text/javascript"><!--' . "\n" . 'document.write(\'' . ($flag_display_large ? '<a href="javascript:popupWindow(\\\'' . str_replace($products_image_large, urlencode(addslashes($products_image_large)), $large_link) . '\\\')">' . $thumb_slashes . '<br />TEXT_CLICK_TO_ENLARGE</a>' : $thumb_slashes) . '\');' . "\n" . '//--></script>';
	//edited for no 'larger image' link
    $noscript_link = '<noscript>' . ($flag_display_large ? '<a href="' . zen_href_link(FILENAME_POPUP_IMAGE_ADDITIONAL, 'pID=' . $_GET['products_id'] . '&pic=' . $i . '&products_image_large_additional=' . $products_image_large) . '" target="_blank">' . $thumb_regular . '<br /><span class="imgLinkAdditional"></span>TEXT_CLICK_TO_ENLARGE</a>' : $thumb_regular ) . '</noscript>';
	//edited for no 'larger image' link
	
      //    $alternate_link = '<a href="' . $products_image_large . '" onclick="javascript:popupWindow(\''. $large_link . '\') return false;" title="' . $products_name . '" target="_blank">' . $thumb_regular . '<br />' . TEXT_CLICK_TO_ENLARGE . '</a>';
$link = '<a href="' .  $base_image . '">' . $thumb_regular . '</a>';
    $link = $script_link . "\n      " . $noscript_link;
     //    $link = $alternate_link;
2 Apr 2014, 2:42 PM
#1055
delia avatar

delia

Totally Zenned

Join Date:
May 2006
Location:
Gardiner, Maine
Posts:
2,383
Plugin Contributions:
7

Re: Image Handler 4 (for v1.5.x) Support Thread

K1ra,

Image swap would be an entirely different mod and I assume you probably overwrote some necessary files when you installed image handler. The image swap javascript or jQuery may also conflict with image handler.

Diva, of worthy note and may have been posted before in this thread:

I installed image handler and ran into a problem with the image on the product page requiring the use of the _MED image which doesn't exist at all. I finally figured out that the ImageMagick version is only 3. So if anyone runs into this problem and checks this thread, perhaps this will be of some use to them.

5 Apr 2014, 7:11 PM
#1056
k1ra avatar

k1ra

New Zenner

Join Date:
Jul 2013
Posts:
57
Plugin Contributions:
0

Re: Image Handler 4 (for v1.5.x) Support Thread

I disabled my image swap as it appears to not work correctly with the new Image Handler. However, I still have a couple issues:

  1. The large image popup is pulling the small image size instead of the large image. I just re-installed the new version of Image Handler.

  2. I uploaded only the Large version of a product image, since IH4 is supposed to auto resize/compress, however all versions of the image are around 20kb, which is the filesize of the Large image I uploaded.

5 Apr 2014, 8:02 PM
#1057
k1ra avatar

k1ra

New Zenner

Join Date:
Jul 2013
Posts:
57
Plugin Contributions:
0

Re: Image Handler 4 (for v1.5.x) Support Thread

k1ra:

I disabled my image swap as it appears to not work correctly with the new Image Handler. However, I still have a couple issues:

  1. The large image popup is pulling the small image size instead of the large image. I just re-installed the new version of Image Handler.

  2. I uploaded only the Large version of a product image, since IH4 is supposed to auto resize/compress, however all versions of the image are around 20kb, which is the filesize of the Large image I uploaded.

I figured out #2. The image name actually had _Lrg in it. I deleted the images, renamed and deleted the _Lrg, and now IH4 works as expected.

I'm still stumped on #1.

5 Apr 2014, 8:33 PM
#1058
trinity14 avatar

trinity14

Zen Follower

Join Date:
Jan 2014
Location:
Ontario, Canada
Posts:
252
Plugin Contributions:
3

Re: Image Handler 4 (for v1.5.x) Support Thread

Your additional images are being forced to be 75px x 100px in your stylesheet.css.

Hope that helps,

5 Apr 2014, 9:18 PM
#1059
divavocals avatar

divavocals

Totally Zenned

Join Date:
Jan 2007
Location:
Los Angeles, California, United States
Posts:
10,011
Plugin Contributions:
3

Re: Image Handler 4 (for v1.5.x) Support Thread

k1ra:

I've got an odd issue. I just upgraded IH4 to the latest version, 4.3.2, and now my image swap does not work. I did not seem to have this problem with IH 4.2.

Image that was just replaced and image swap is not swapping correct image:

r o s e c i t y v i n t a g e [dot] com/index.php?main_page=product_info&cPath=1_5&products_id=384

Image that for some reason is not being resized, and working correctly

r o s e c i t y v i n t a g e [dot] com/index.php?main_page=product_info&cPath=1_5&products_id=74

My modified code in modules/additional_images.php is in red and TEXT_CLICK_TO_ENLARGE has been removed:

$thumb_regular = zen_image($base_image, $products_name, MEDIUM_IMAGE_WIDTH, MEDIUM_IMAGE_HEIGHT);
$large_link = zen_href_link(FILENAME_POPUP_IMAGE_ADDITIONAL, 'pID=' . $_GET['products_id'] . '&pic=' . $i . '&products_image_large_additional=' . $products_image_large);

// Link Preparation:
$script_link = '<script language="javascript" type="text/javascript"><!--' . "\n" . 'document.write(\'' . ($flag_display_large ? '<a href="javascript:popupWindow(\\\'' . str_replace($products_image_large, urlencode(addslashes($products_image_large)), $large_link) . '\\\')">' . $thumb_slashes . '<br />TEXT_CLICK_TO_ENLARGE</a>' : $thumb_slashes) . '\');' . "\n" . '//--></script>';
//edited for no 'larger image' link
$noscript_link = '<noscript>' . ($flag_display_large ? '<a href="' . zen_href_link(FILENAME_POPUP_IMAGE_ADDITIONAL, 'pID=' . $_GET['products_id'] . '&pic=' . $i . '&products_image_large_additional=' . $products_image_large) . '" target="_blank">' . $thumb_regular . '<br /><span class="imgLinkAdditional"></span>TEXT_CLICK_TO_ENLARGE</a>' : $thumb_regular ) . '</noscript>';
//edited for no 'larger image' link

  //    $alternate_link = '<a href="' . $products_image_large . '" onclick="javascript:popupWindow(\''. $large_link . '\') return false;" title="' . $products_name . '" target="_blank">' . $thumb_regular . '<br />' . TEXT_CLICK_TO_ENLARGE . '</a>';

$link = '<a href="' . $base_image . '">' . $thumb_regular . '</a>';
$link = $script_link . "\n " . $noscript_link;
// $link = $alternate_link;

Not to be nit picky.. but I personally found it was a PITA to put back together your URL JUST to look at the links you posted.. So I just looked at this today because I have time for playing with a copy, paste, and reassemble puzzle to take a look at your link.. (might be why not many folks responded to your question..)

going forward if you want to post links that don't gt picked up my the search engines simply typing <http://rosecityvintage>[dot]com/index.php?main_page=product_info&cPath=1_5&products_id=74 (without all the extra spaces) would have done the trick..

> **Trinity14:**
>
> Your additional images are being forced to be 75px x 100px in your stylesheet.css.
> 
> Hope that helps,

Not just additional images but their sidebox images too..


.sideBoxContent img { 	width:100px; 	height:75px; 	}

Furthermore NONE of the product images appear to be managed by IH4 at all.. So in short IH4 is installed wrong..
5 Apr 2014, 9:32 PM
#1060
k1ra avatar

k1ra

New Zenner

Join Date:
Jul 2013
Posts:
57
Plugin Contributions:
0

Re: Image Handler 4 (for v1.5.x) Support Thread

DivaVocals:

Not to be nit picky.. but I personally found it was a PITA to put back together your URL JUST to look at the links you posted.. So I just looked at this today because I have time for playing with a copy, paste, and reassemble puzzle to take a look at your link.. (might be why not many folks responded to your question..)

going forward if you want to post links that don't gt picked up my the search engines simply typing http://rosecityvintage[dot]com/index.php?main_page=product_info&cPath=1_5&products_id=74 (without all the extra spaces) would have done the trick..

Not just additional images but their sidebox images too..

.sideBoxContent img { width:100px; height:75px; }

Furthermore NONE of the product images appear to be managed by IH4 at all.. So in short IH4 is installed wrong..

Thanks. I'll remember that! It's much easier..

Yes the additional images are being forced to a smaller size in the css so they fit in the product_info page. Are you saying that is what is causing the popup to not pull the lrg images?

I re-installed IH4 twice this morning just in case I missed something, disabled the code for my image swap [which was custom], then deleted and re-uploaded the images for this product an hour ago:

http://rosecityvintage[dot]com/index.php?main_page=product_info&cPath=1_5&products_id=749

The src seems to show the images coming from IH4 cache, but the source for the popup seems to be for the same image instead of for the _Lrg image, or the image.600x800 as IH names it.

The images at the link provided are they only product who's images I have put through IH4. All other product images were created manually with the zen naming convention and the various sizes. These will be replaced eventually.

Thank you for responding. I have been stumped on this.