Zen Cart Logo
Forums / All Other Contributions/Addons / Image Handler 2 (for ZC v1.3.8 ONLY) Support

Image Handler 2 (for ZC v1.3.8 ONLY) Support

Views: 2,510,546

Results 6,721 to 6,740 of 7,094
17 Apr 2011, 9:55 PM
#6721
nigelt74 avatar

nigelt74

Totally Zenned

Join Date:
Sep 2005
Location:
Waikato, New Zealand
Posts:
1,558
Plugin Contributions:
1

Image Handler 2 (for ZC v1.3.8 ONLY) Support

DivaVocals:

Wanted to update folks.. I just tried and tested the change suggested in this referenced thread, and it appears to work.. :clap:

So I'll update the upcoming release with these changes (pending confirmation of identical results from the folks testing the new release..)

You know I had been looking at that problem after the discussion the other day, I was going to do the same thing via filetype but the way in that link is a much quicker less server intensive way.

However the one advantage filetypes had is they deal with jpeg & jpg, so what about adding the option to deal with the jpeg vs jpg issue, below that code

$data['imgExtension'] = strtolower($data['imgExtension']);
if ($data['imgExtension'] == "jpeg") {$data['imgExtension'] = "jpg"; }

17 Apr 2011, 10:10 PM
#6722
scriptjunkie avatar

scriptjunkie

Totally Zenned

Join Date:
Jul 2008
Posts:
772
Plugin Contributions:
0

Re: Image Handler 2 (for ZC v1.3.8 ONLY) Support

Which file are we talking about editing? Because the one discussed here http://www.zen-cart.com/forum/showthread.php?t=84164
has a file path that doesn't exist in the most recent version (admin/includes/module/ih_manger.php)

I tried making these edits in admin/includes/ih_manager.php but it didn't work. Perhaps I'm editing the wrong file?

17 Apr 2011, 10:54 PM
#6723
divavocals avatar

divavocals

Totally Zenned

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

Re: Image Handler 2 (for ZC v1.3.8 ONLY) Support

nigelt74:

You know I had been looking at that problem after the discussion the other day, I was going to do the same thing via filetype but the way in that link is a much quicker less server intensive way.

However the one advantage filetypes had is they deal with jpeg & jpg, so what about adding the option to deal with the jpeg vs jpg issue, below that code

$data['imgExtension'] = strtolower($data['imgExtension']);
if ($data['imgExtension'] == "jpeg") {$data['imgExtension'] = "jpg"; }Just want to make sure I understand what it is that this code resolves:

  1. Convert lowercase file extensions to lowercase (JPG to jpg OR PNG to png)
  2. If the file extension = jpeg, covert it to jpg
    Am I understanding this correctly??? If so I'll add to the code, and we can all test to be sure we get the same results..

ScriptJunkie:

Which file are we talking about editing? Because the one discussed here http://www.zen-cart.com/forum/showthread.php?t=84164
has a file path that doesn't exist in the most recent version (admin/includes/module/ih_manger.php)

I tried making these edits in admin/includes/ih_manager.php but it didn't work. Perhaps I'm editing the wrong file?I'll FTP over the updated file in a few.. (Making omelets right now!:smile:)

17 Apr 2011, 11:05 PM
#6724
divavocals avatar

divavocals

Totally Zenned

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

Re: Image Handler 2 (for ZC v1.3.8 ONLY) Support

DivaVocals:

I'll FTP over the updated file in a few.. (Making omelets right now!:smile:)You've got mail!! (check the FTP folder)

17 Apr 2011, 11:20 PM
#6725
scriptjunkie avatar

scriptjunkie

Totally Zenned

Join Date:
Jul 2008
Posts:
772
Plugin Contributions:
0

Re: Image Handler 2 (for ZC v1.3.8 ONLY) Support

DivaVocals:

You've got mail!! (check the FTP folder)

Ok...because all my file extensions are uniform, here's what I did to prepare my site to test this bit of code change:

For the images on this page, I used FTP to make the following changes:

  • main image file extension kept as .jpg
  • first additional image file extension changed to .JPG
  • second additional image file extension changed to .jpeg
  • cleared the bmz_cache folder
  • uploaded the new file you FTP'd over (which, except for the comments you added, is identical to the changes I made based on this thread discussion)
    Then I cleared the browser cache and relaunched the browser. Went to the above page and no additional images show.

Did you make a change to more than one file? (I didn't upload the entire package...just the ih_manager.php file)

17 Apr 2011, 11:47 PM
#6726
scriptjunkie avatar

scriptjunkie

Totally Zenned

Join Date:
Jul 2008
Posts:
772
Plugin Contributions:
0

Re: Image Handler 2 (for ZC v1.3.8 ONLY) Support

Further....Firebug doesn't even see the section of the page where additional images are stored....As I type this...I just thought of something...let me go back to IH Manager and make the changes there.

BRB

17 Apr 2011, 11:57 PM
#6727
scriptjunkie avatar

scriptjunkie

Totally Zenned

Join Date:
Jul 2008
Posts:
772
Plugin Contributions:
0

Re: Image Handler 2 (for ZC v1.3.8 ONLY) Support

No change

18 Apr 2011, 12:18 AM
#6728
nigelt74 avatar

nigelt74

Totally Zenned

Join Date:
Sep 2005
Location:
Waikato, New Zealand
Posts:
1,558
Plugin Contributions:
1

Re: Image Handler 2 (for ZC v1.3.8 ONLY) Support

DivaVocals:

Just want to make sure I understand what it is that this code resolves:

  1. Convert lowercase file extensions to lowercase (JPG to jpg OR PNG to png)
  1. If the file extension = jpeg, covert it to jpg

Am I understanding this correctly??? If so I'll add to the code, and we can all test to be sure we get the same results..

jpeg code doesn't work for me, drat I'll actually have to think about it.

18 Apr 2011, 12:22 AM
#6729
nigelt74 avatar

nigelt74

Totally Zenned

Join Date:
Sep 2005
Location:
Waikato, New Zealand
Posts:
1,558
Plugin Contributions:
1

Re: Image Handler 2 (for ZC v1.3.8 ONLY) Support

ScriptJunkie:

Ok...because all my file extensions are uniform, here's what I did to prepare my site to test this bit of code change:

For the images on this page, I used FTP to make the following changes:

  • main image file extension kept as .jpg
  • first additional image file extension changed to .JPG
  • second additional image file extension changed to .jpeg
  • cleared the bmz_cache folder
  • uploaded the new file you FTP'd over (which, except for the comments you added, is identical to the changes I made based on this thread discussion)

Then I cleared the browser cache and relaunched the browser. Went to the above page and no additional images show.

Did you make a change to more than one file? (I didn't upload the entire package...just the ih_manager.php file)

the changes mentioned, only effect images uploaded via image handlers add additional image thingie in admin, it doesn't touch any files that have been ftpd.

for instance if you upload an image called bob.JPG (via the additional images) it will be renamed to bob.jpg

actually I wonder what happens if you first product image added in the add products section is bob.JPG

-------------------------------------------Edit

Problem

if your first image is .JPG, then the code addition will make your next image you add (via additional images) a .jpg, and therefore invisible in the store

18 Apr 2011, 12:24 AM
#6730
scriptjunkie avatar

scriptjunkie

Totally Zenned

Join Date:
Jul 2008
Posts:
772
Plugin Contributions:
0

Re: Image Handler 2 (for ZC v1.3.8 ONLY) Support

nigelt74:

the changes mentioned, only effect images uploaded via image handlers add additional image thingie in admin, it doesn't touch any files that have been ftpd.

for instance if you upload an image called bob.JPG (via the additional images) it will be renamed to bob.jpg

actually I wonder what happens if you first product image added in the add products section is bob.JPG

I wanted to try and test that (delete the images and re-upload via IH's image uploading functionality...but before I can do it, I have to change the file extensions on my computer. BUT, when I try and do that, windows insists on putting them all back to .jpg...i.e. when I take a .jpg file and rename it .JPG, Windows defaults it back to .jpg.

Grrrr

18 Apr 2011, 12:30 AM
#6731
sunrise99 avatar

sunrise99

New Zenner

Join Date:
Apr 2008
Posts:
41
Plugin Contributions:
3

Re: Image Handler 2 (for ZC v1.3.8 ONLY) Support

I install serval ZC139 for this module 2.0 Rev 8d

most of them can't work!! The install is very simply, I don't know why they can't work. admin setting is correct.

Best Regards,

18 Apr 2011, 12:45 AM
#6732
nigelt74 avatar

nigelt74

Totally Zenned

Join Date:
Sep 2005
Location:
Waikato, New Zealand
Posts:
1,558
Plugin Contributions:
1

Re: Image Handler 2 (for ZC v1.3.8 ONLY) Support

sunrise99:

I install serval ZC139 for this module 2.0 Rev 8d

most of them can't work!! The install is very simply, I don't know why they can't work. admin setting is correct.

Best Regards,

  1. Provide a link
  2. Explain what is not working
  3. Did you rename all the Your_template directories to match the name of your template
18 Apr 2011, 4:47 AM
#6733
divavocals avatar

divavocals

Totally Zenned

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

Re: Image Handler 2 (for ZC v1.3.8 ONLY) Support

sunrise99:

I install serval ZC139 for this module 2.0 Rev 8d

most of them can't work!! The install is very simply, I don't know why they can't work. admin setting is correct.

Best Regards,

nigelt74:

  1. Provide a link
  2. Explain what is not working
  3. Did you rename all the Your_template directories to match the name of your template

What nigel said.. Which is pretty much the same thing I told you when I replied to your initial post here:
http://www.zen-cart.com/forum/showpost.php?p=1017951&postcount=6703

Telling us "it's broken" tells us nothing.. You need to go back over the readme, check your install and then come back and provide DETAILS as nigel has suggested..

18 Apr 2011, 4:48 AM
#6734
divavocals avatar

divavocals

Totally Zenned

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

Re: Image Handler 2 (for ZC v1.3.8 ONLY) Support

nigelt74:

jpeg code doesn't work for me, drat I'll actually have to think about it.

nigelt74:

Problem

if your first image is .JPG, then the code addition will make your next image you add (via additional images) a .jpg, and therefore invisible in the store

nods in agreement so I will be rolling both of those changes back..

18 Apr 2011, 5:03 AM
#6735
divavocals avatar

divavocals

Totally Zenned

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

Re: Image Handler 2 (for ZC v1.3.8 ONLY) Support

Okay.. I rolled back the JPEG change, but the case change I have no problem working regardless as to which image was uploaded first. If the 1st image uploaded is uppercase, it converts to lowercase, and vice versa..

18 Apr 2011, 5:38 AM
#6736
nigelt74 avatar

nigelt74

Totally Zenned

Join Date:
Sep 2005
Location:
Waikato, New Zealand
Posts:
1,558
Plugin Contributions:
1

Re: Image Handler 2 (for ZC v1.3.8 ONLY) Support

DivaVocals:

Okay.. I rolled back the JPEG change, but the case change I have no problem working regardless as to which image was uploaded first. If the 1st image uploaded is uppercase, it converts to lowercase, and vice versa..
Not if the first image is uploaded via the "add new product" page, the image in that case will retain its case.

So your main image is bob.JPG (uploaded via the new product page)
when you add an additional image it will be named
bob_01.jpg
Which won't show up in the storefront because the extension is a different case

But i've just emailed you an alteration that will make all uploaded additional images have the same extensions (providing they are the same filetype)as the main image for that product.

So if your base image is bob.jpg

And you upload the additional image bill.JPEG it will be renamed to bob_01.jpg

or if your base image is bob.jpeg

And you upload the additional image bill.JPG it will be renamed to bob_01.jpeg

18 Apr 2011, 5:43 AM
#6737
divavocals avatar

divavocals

Totally Zenned

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

Re: Image Handler 2 (for ZC v1.3.8 ONLY) Support

Got it.. I was using the IH2 interface or FTP to upload images..

I got your e-mail.. I e-mailed you back a question regarding the IH2 filetype settings and your new code.. :smile:

nigelt74:

Not if the first image is uploaded via the "add new product" page, the image in that case will retain its case.

So your main image is bob.JPG (uploaded via the new product page)
when you add an additional image it will be named
bob_01.jpg
Which won't show up in the storefront because the extension is a different case

But i've just emailed you an alteration that will make all uploaded additional images have the same extensions (providing they are the same filetype)as the main image for that product.

So if your base image is bob.jpg

And you upload the additional image bill.JPEG it will be renamed to bob_01.jpg

or if your base image is bob.jpeg

And you upload the additional image bill.JPG it will be renamed to bob_01.jpeg

18 Apr 2011, 6:16 AM
#6738
ideasgirl avatar

ideasgirl

Totally Zenned

Join Date:
Aug 2005
Location:
Trujillo Alto, Puerto Rico
Posts:
1,437
Plugin Contributions:
3

Re: Image Handler 2 (for ZC v1.3.8 ONLY) Support

Nigel, you haven't answered my question. :mellow:

18 Apr 2011, 8:34 AM
#6739
nigelt74 avatar

nigelt74

Totally Zenned

Join Date:
Sep 2005
Location:
Waikato, New Zealand
Posts:
1,558
Plugin Contributions:
1

Re: Image Handler 2 (for ZC v1.3.8 ONLY) Support

ideasgirl:

I think that's an issue with the hover itself. I just took off the hotzone and has same behavior (I don't have Opera, please check).
Just for you, and yes i am grumpy because i'm jealous, freezing cold and rainy here with a small early morning earthquake.

Opera is not working at all on your site now

Did you update the javascript to the newer version, as the current version doesn't work correctly with Internet explorer 9

the version you have was the one with the fold issues in some browsers and extremely bad support for chrome and opera, the current js file is backwards compatible with pretty much any installation of IH2, so you can just upload the js file over top of the existing one
a good test is to wait for the page to load, then scroll to the bottom of the page and try the hover over the bottom images, if you don't see the hover then you have the old version

18 Apr 2011, 10:25 AM
#6740
hayesphilip avatar

hayesphilip

New Zenner

Join Date:
Nov 2007
Posts:
3
Plugin Contributions:
0

Re: Image Handler 2 (for ZC v1.3.8 ONLY) Support

Hi,
If you get this error: Warning: strstr() [function.strstr]: Empty delimiter in XXXXXX when using image handler, check that you have an entry for Product Info - Image Medium Suffix and Product Info - Image Large Suffix under the Images section. I entered "_MED" and "_LRG" in here and it solved the problem for me.

Regards,
Philip Hayes
www.deewhy.ie