-
Re: Image Handler 2 Support
I was trying to solve a problem.
My Image Hoover was not working anymore.
I saw there was an upgrade to Image Hander so I installed it.
When I installed it I got this error.
Quote:
Fatal error: Call to undefined function zen_attribute_image() in /home/noah/public_html/includes/modules/zencart_zen/attributes.php on line 481
Not knowing what to do I commented out the line (491)
Quote:
// $tmp_attributes_image .= '<div class="attribImg">' . zen_attribute_image(DIR_WS_IMAGES . $products_options->fields['attributes_image']) . (PRODUCT_IMAGES_ATTRIBUTES_NAMES == '1' ? '<br />' . $products_options->fields['products_options_values_name'] : '') . '</div>' . "\n";
Oh but now My Attribute Images are not showing up...
What can I do to fix this???
If image hoover is just not working.. Any suggestions on what to do?
-
Re: Image Handler 2 Support
Quote:
Originally Posted by
kuroi
If the PHP interpreter reaches the end of a file with its tag state as open, it will close it automatically. So ?> at the end of a file are actually optional. I would argue that best practise would be to include a closing tag anyway, but the author of Image Handler always preferred to leave them off. So there's no surprise that there's not one here.
Indeed, this FAQ Entry shows that ?> end tags are beginning to disappear from Zen Cart's core code too and gives a good reason for this. Looks like I might need to review my perception of best practise!
-
Re: Image Handler 2 Support
I recently installed IH2 Version: 2.0_for_137 from 10/21/07.
I was wondering what to do with category_product_listing.php.patch
admin/includes/modules/category_product_listing.php.patch
do I leave that out of the install? or do I patch something with the code in this file?
php.patch can't be executed right?
-
Re: Image Handler 2 Support
I am having problems with my images not showing up in the SSL(https) section of my website (i.e log-in , my account ect). I have installed and re-installed image handler 2.0 twice. I have the latest version of zen cart (v1.3.8a)
What could be the problem? Please, any help would be wonderful.
my site is at http://www.cherrytreecreations.com
-
Re: Image Handler 2 Support
Quote:
Originally Posted by
cherrytreecreations
I am having problems with my images not showing up in the SSL(https) section of my website (i.e log-in , my account ect). I have installed and re-installed image handler 2.0 twice. I have the latest version of zen cart (v1.3.8a)
What could be the problem? Please, any help would be wonderful.
my site is at
http://www.cherrytreecreations.com
Was the site an upgrade?
Try deleting what resides inside the bmz_cache folder and checking that the folder has the correct permissions.
Also what's the size of your large images without image handler having resized them. The largest image you uploaded.
-
Re: Image Handler 2 Support
Quote:
Originally Posted by
bjornarl
Since upgrading to 1.3.8a on our shared server account, we have been told the site is generating excessive resource usage and will soon be moved off the server. Stats given were:
CPU usage: 2.52
Memory usage: 1.19
MySQL usage: 0.2
Other than content customizations and a handful of mods, it's a pretty standard install. However when I disabled Image Handler 2 in the admin (setting "IH resize images" to "no") the page parse times do drop noticeably... when it's on they are up to 10 seconds (worst case) and when it's off they are usually under 2 seconds. Database query time is always low (< 0.5 seconds).
Has anyone else run into this problem with Zen Cart 1.3.8a on PHP5 with gd with Image Handler 2?
I have checked when IH2 is on that all images on the page are using the cached generated images (they are), and when I browse the cache directories on the server the timestamps are not new -- i.e. the cached images are not being regenerated each time the page displayed (or if they are, at least not resaved).
I did upgrade the site via a subversion branch merge and I don't believe there were direct conflicts in the IH2 files. There are no visible problems on the site with IH2 active.
Thanks for any suggestions on what could be wrong.
Bjornar
Do you have a link to the site ... what's the quality setting under Configuration :: Images?
Are there lots of images loading on a single page ...
And it could possibly be that your site is generating enough traffic that it's in the best interest of your hosting company to move you onto a better server.
-
Re: Image Handler 2 Support
Hi,
Does anyone know why every now and then I have to reinstall IH2? I mean I have previously installed it but after a while the IH2 admin shows the following. The image zooming effect is still working on my website though.
* Install Image Handler
* Clear image cache
* Scan for old IH 0.x and 1.x original images
Please advise. Thanks in advance.
-
Re: Image Handler 2 Support
My bmz_cache is getting big, especially for backups.
I went to the IH2 admin, and cleared cache "Image cache cleared" statement appeared, checked the bmz_cache folder, a file called .keep was deleted but the folders and images remain...Do I FTP delete them?
and if so, is this how to do it in future, delete the folders first, then clear cache in admin? not sure what clear cache in admin does then...
-
Re: Image Handler 2 Support
[FONT=Times New Roman]I set up in admin to use the watermark on large images, I also made sure I have the watermark.png image in my large folder, but still it not working on large images.[/FONT]
[FONT=Times New Roman] When I set up medium images and activate it from the admin it work perfect.[/FONT]
[FONT=Times New Roman][/FONT]
[FONT=Times New Roman]But I only trying to have it for large images[/FONT]
[FONT=Times New Roman][/FONT]
[FONT=Times New Roman]Any idea what I am missing?[/FONT]
[FONT=Times New Roman][/FONT]
[FONT=Times New Roman]Thank you [/FONT]
-
Re: Image Handler 2 Support
Excuse the complete Newbie question. I have to upload thouands of product images, since I switched from Volusion to Zencart. In Volusion i would FTP the images to my "images" folder. I just went to my Zencart FTp site and cannot find a folder for: images, images/medium and images/large directories.
Where are they? Do I have to create them? Please provide an explicit repsonse for the Zen challenged.
Does Image Handler help with this?
Thank you!
-
Re: Image Handler 2 Support
Hi All,
Great thread for a great add-on!
Unfortunately though after 3 months of use, the Image Handler seems to have 'broken' (though I suspect my client is somehow responsible for this). Basically, when you try to add an image a number of strange things happen:
1. The Image Handler does not create medium/large images automatically, thus when a product image is clicked on a broken image link appears
2. The Image Handler has stopped adding additional images to the correct products! After submitting a new image via the Image Handler it will appear in the admin area, but when visiting the product page the additional images are not there!
Basically things are pretty messed up and I'm not sure how best to go about correcting the issues. If I delete the current Image Handler files and re-install the module will this correct the problems?
-
Re: Image Handler 2 Support
After searching this thread for 2 days, I finally found the problem I was having with a new install. For some reason the pop ups where not working from a certain point on in each category. Everything before the cutoff worked, everything after, didn't.
My client was using quotes in his product names. It finally hit me that the products that worked had double quotes and the ones that didn't used single quotes. After renaming all of the single quote images, eveything started working.
Hope this helps someone else!!!
-
Re: Image Handler 2 Support
I'm gradually going through all these pages and have fixed the hover error I was getting but am still not able to determine the cause of the Syntax Error I get everytime I try to load a page - has anyone else had this problem??
-
Re: Image Handler 2 Support
Quote:
Originally Posted by
Lou
I'm gradually going through all these pages and have fixed the hover error I was getting but am still not able to determine the cause of the Syntax Error I get everytime I try to load a page - has anyone else had this problem??
It seems something weird was going on with some of the images from one of the products (for some reason it was showing a blank box and "no info" for the medium size) - as soon as I deleted the images for that product and uploaded some new ones, the syntax error has disappeared.
-
Re: Image Handler 2 Support
Quote:
Originally Posted by
dealbyethan.com
Hi,
Does anyone know why every now and then I have to reinstall IH2? I mean I have previously installed it but after a while the IH2 admin shows the following. The image zooming effect is still working on my website though.
* Install Image Handler
* Clear image cache
* Scan for old IH 0.x and 1.x original images
Please advise. Thanks in advance.
Try optimizing your DB from phpMyAdmin. Sometimes the tables become full of junk and IH gets confused. Optimizing the db has corrected this issue many times. And although it says it needs to be re-installed, it actually is still there and in full effect. I would do one thing though and check the version of IH, just to be safe.
Quote:
Originally Posted by
dharma
My bmz_cache is getting big, especially for backups.
I went to the IH2 admin, and cleared cache "Image cache cleared" statement appeared, checked the bmz_cache folder, a file called .keep was deleted but the folders and images remain...Do I FTP delete them?
and if so, is this how to do it in future, delete the folders first, then clear cache in admin? not sure what clear cache in admin does then...
Deleting the images via FTP is safe and what you'd normally have to do if the option in the Admin wasn't given to you. Some servers don't allow you to run file commands ... get a hold of your server admins for that.
Quote:
Originally Posted by
kbmets7
Excuse the complete Newbie question. I have to upload thouands of product images, since I switched from Volusion to Zencart. In Volusion i would FTP the images to my "images" folder. I just went to my Zencart FTp site and cannot find a folder for: images, images/medium and images/large directories.
Where are they? Do I have to create them? Please provide an explicit repsonse for the Zen challenged.
Does Image Handler help with this?
Thank you!
Those folders should be there by default, as Zen Cart comes pre-packaged with a ready-to-go demo store. But nevertheless if the folders aren't there, create them. Especially the images folder, it's actually needed for proper function of Zen Cart (you can re-name the images folder in your configure.php files if need be).
Quote:
Originally Posted by
DiZZ
Hi All,
Great thread for a great add-on!
Unfortunately though after 3 months of use, the Image Handler seems to have 'broken' (though I suspect my client is somehow responsible for this). Basically, when you try to add an image a number of strange things happen:
1. The Image Handler does not create medium/large images automatically, thus when a product image is clicked on a broken image link appears
2. The Image Handler has stopped adding additional images to the correct products! After submitting a new image via the Image Handler it will appear in the admin area, but when visiting the product page the additional images are not there!
Basically things are pretty messed up and I'm not sure how best to go about correcting the issues. If I delete the current Image Handler files and re-install the module will this correct the problems?
Sounds like things have gotten a bit messed up and there has probably been some changes to IH specific files. I'd try re-installing IH from scratch and see if that corrects the problems your having. If it doesn't, come back we'll track them down.
-
Re: Image Handler 2 Support
Quote:
Originally Posted by
motti
[FONT=Times New Roman]I set up in admin to use the watermark on large images, I also made sure I have the watermark.png image in my large folder, but still it not working on large images.[/FONT]
[FONT=Times New Roman] When I set up medium images and activate it from the admin it work perfect.[/FONT]
[FONT=Times New Roman]But I only trying to have it for large images[/FONT]
[FONT=Times New Roman]Any idea what I am missing?[/FONT]
[FONT=Times New Roman]Thank you [/FONT]
Left this one out of my first reply, sorry about that.
Common cause for this is that your large images aren't even being touched by Image Handler.
Check the links to your large images and make sure that tthey're coming from the bmz_cache directory. If they're not, under Configuration :: Images you'll need to modify your large image dimensions and whether or not IH needs to affect them.
-
Re: Image Handler 2 Support
Quote:
Originally Posted by
testuser
Image Handler works from the time you install it on already active products and products you choose to install later.
Ok, I have already loaded 15k large product images via FTP. if I install Image handler now, are you saying that those 15k images will get resized by Image Handler?
-
Re: Image Handler 2 Support
Testuser,
Thanks very much for the reply! Unfortunately after uninstalling/reinstalling the Image Handler none of the problems were corrected...
But let me ask you this - could product linking affect where the Image Handler adds images at all? My client has about 2000 products, and from what I can tell the product linking is becoming somewhat arcane - would this have any effect on the Image Handler?
Sorry to be a pest, I'm just trying to troubleshoot...
-
Re: Image Handler 2 Support
Quote:
Originally Posted by
kbmets7
Ok, I have already loaded 15k large product images via FTP. if I install Image handler now, are you saying that those 15k images will get resized by Image Handler?
Only if the settings under Configuration :: Images affect the images you've already uploaded. If you don't want to have an image resized, there's a setting in the same place that allows you to name a suffix for images that don't need resizing. Any image with this suffix IH will skip handling.
Quote:
Originally Posted by
DiZZ
Testuser,
Thanks very much for the reply! Unfortunately after uninstalling/reinstalling the Image Handler none of the problems were corrected...
But let me ask you this - could product linking affect where the Image Handler adds images at all? My client has about 2000 products, and from what I can tell the product linking is becoming somewhat arcane - would this have any effect on the Image Handler?
Sorry to be a pest, I'm just trying to troubleshoot...
That's stinks ... do you have a link to the site? Linking shouldn't be the issue ...
-
multiple images
Ihave several items in my catalog that show different items in the main picture so if I have 10 items shown in the picture I'll have 10 items that have the same picture when the item number is displayed.
Using IH2, I noticed that when I try to add other images to each of those 10 items to show the detail of the actual item in the picture, by the time I get through them, all have the same additional picture.
So if one of the items shows a picture on the wall and one items shows a bedspread, all items are going to have the picture on the wall shown when you view the product.
Is this because although the item number is different the subsequent image links to the image of the product?
Is there a way I can do this?
-
Re: multiple images
Quote:
Originally Posted by
Rob905
Ihave several items in my catalog that show different items in the main picture so if I have 10 items shown in the picture I'll have 10 items that have the same picture when the item number is displayed.
Using IH2, I noticed that when I try to add other images to each of those 10 items to show the detail of the actual item in the picture, by the time I get through them, all have the same additional picture.
So if one of the items shows a picture on the wall and one items shows a bedspread, all items are going to have the picture on the wall shown when you view the product.
Is this because although the item number is different the subsequent image links to the image of the product?
Is there a way I can do this?
Additional images are a bit difficult and I've seen this numerous times.
If your images are named similar such as:
product_bed.gif
product_lamp.gif
And in the same folder and you have a product with a product image of:
product.gif
The product with product.gif will include additional product images:
product_bed.gif
product_lamp.gif
Ok, now here's why. Additional images go based on the prefix, in this case product. Because your main product image is product.gif Zen realizes that product is the prefix for the two other images and attaches them to this product.
Instead try naming the images like so.
product.gif
lamp_product.gif
bed_product.gif
This will unlink them and your product will now only have one image. Hope that makes since.
-
Re: multiple images
I installed IH2 on my zen cart. The file transfer seemed to go fine.
I selected the IH2 install from the Admin>Tools>IH2
Then BLAMO, nothing on my site. The store page brings up an empty white page.
I can still log into the Zen Cart admin page, all of the products are there.
So my guess is there is a pointer pointing to the wrong place.
I'll go over what I can to try and figure out what I screwed up.
Zen Cart 1.3.8
Database Patch Level: 1.3.8
-
Re: multiple images
Any tips? I still can't get my store front to re-appear.
I selected uninstall from the Admin menu, and still nothing.
-
Re: multiple images
Quote:
Originally Posted by
testuser
Additional images are a bit difficult and I've seen this numerous times.
If your images are named similar such as:
product_bed.gif
product_lamp.gif
And in the same folder and you have a product with a product image of:
product.gif
The product with product.gif will include additional product images:
product_bed.gif
product_lamp.gif
Ok, now here's why. Additional images go based on the prefix, in this case product. Because your main product image is product.gif Zen realizes that product is the prefix for the two other images and attaches them to this product.
Instead try naming the images like so.
product.gif
lamp_product.gif
bed_product.gif
This will unlink them and your product will now only have one image. Hope that makes since.
Unfortunately, even if I use an image name that is not related, IE 37239 for the main item and then 37246, 37244, 37241 etc for the individual items, it seems to keep the last item that I added for each of the items that has 37239 as the main picture.
-
Re: Image Handler 2 Support
The Hoover Image is part of IH2 Right?
What I was looking for is how I can get the hoover image to work over my attribute sample images.
-
Re: Image Handler 2 Support
An extremely basic question:
I downloaded image handler to my desktop. Now I have to install it. How do I do this?
Do I place the entire folder in one of my directories, via FTP? Is there a forum or place that explains how to install modules (for dummies)?
-
Re: Image Handler 2 Support
Quote:
Originally Posted by
kbmets7
An extremely basic question:
I downloaded image handler to my desktop. Now I have to install it. How do I do this?
Do I place the entire folder in one of my directories, via FTP? Is there a forum or place that explains how to install modules (for dummies)?
Un-Zip or extract the files to a folder on your desktop. there should be a file called readme.txt or install.txt in the folder. That will give you the information you need to set it up.
JOhn ><>
-
Re: Image Handler 2 Support
Thanks for the response. The Readme files says:
"The folders
you need to upload to your server are the following.
* admin
* bmz_cache
* images
* includes"
Do I upload them to the main landing page (when I initially connect via FTP). Or do I create a new directory, and place them in there?
-
Re: multiple images
Quote:
Originally Posted by
tacoma
I installed IH2 on my zen cart. The file transfer seemed to go fine.
I selected the IH2 install from the Admin>Tools>IH2
Then BLAMO, nothing on my site. The store page brings up an empty white page.
I can still log into the Zen Cart admin page, all of the products are there.
So my guess is there is a pointer pointing to the wrong place.
I'll go over what I can to try and figure out what I screwed up.
Zen Cart 1.3.8
Database Patch Level: 1.3.8
So somehow my includes/functions/html_output.php file moved to includes/functions/extra_functions.
That is some weird stuff.
-
Re: multiple images
Quote:
Originally Posted by
tacoma
So somehow my includes/functions/html_output.php file moved to includes/functions/extra_functions.
That is some weird stuff.
What version are you using?
The latest versions don't have html_output.php.
Latest versions in Downloads.
http://www.zen-cart.com/index.php?ma...roducts_id=117
M
-
Re: multiple images
Quote:
Originally Posted by
tophand
It says - Image Handler 2.0 for Zen-Cart v1.3.x
I got it from the website. It's clearly a revision or two behind.
-
Re: Image Handler 2 Support
Quote:
Originally Posted by
kbmets7
Thanks for the response. The Readme files says:
"The folders
you need to upload to your server are the following.
* admin
* bmz_cache
* images
* includes"
Do I upload them to the main landing page (when I initially connect via FTP). Or do I create a new directory, and place them in there?
1) Before adding or making changes to your site, "Back It Up"!
2) Image Handler files, open "includes" -->"templates" and rename the folder "template custom" to the name of the template you are using.
2-A) If your using template overrides you need to check to be sure your not going to overwrite your custom changes.
3) FTP, if you can see on your site, "admin", "images" and "includes" your at the right place. Just upload the the Image Handler folders and follow the rest of the instructions.
M
-
Re: multiple images
Quote:
Originally Posted by
tacoma
It says - Image Handler 2.0 for Zen-Cart v1.3.x
I got it from the website. It's clearly a revision or two behind.
Get the latest version.
M
-
Re: Image Handler 2 Support
Quote:
Originally Posted by
milobloom
The Hoover Image is part of IH2 Right?
What I was looking for is how I can get the hoover image to work over my attribute sample images.
There is another mod that work with attribute images.
Check in the downloads area.
M
-
Re: Image Handler 2 Support
Does anyone know of where I can get the mod to hoover over attribute images???
-
Re: multiple images
Quote:
Originally Posted by
tophand
Get the latest version.
M
I will probably come back to it later. I thought I was out of luck, and now a little gun shy.
Being an older revision would help explain some install issues.
-
Re: Image Handler 2 Support
Quote:
Originally Posted by
milobloom
Does anyone know of where I can get the mod to hoover over attribute images???
This is the mod I was thinking about when I posted earlier.
http://www.zen-cart.com/index.php?ma...roducts_id=616
M
-
Re: Image Handler 2 Support
Quote:
Originally Posted by
tophand
Thank you for the info.
Looks like a nice mode that I might also have use for.
marksu
-
Re: Image Handler 2 Support
Would it be possible/useful to incorporate the manufacturers name and/or product name into the filenames IH generates within the bmz_cache directory? I'm asking because I was wondering if this could have an affect with regard to SEO.
Maybe if IH could rewrite a path like
bmz_cache/d/d8418ec3b6e231502512ada44ec5ed62.image.135x89.JPG
to (for example)
bmz_cache/d/d8418ec3b6e231502512ada44ec5ed62.microsoft.image.135x89.JPG
or
bmz_cache/d/d8418ec3b6e231502512ada44ec5ed62.microsoft.vista.image.135x89.JPG
searchengines would pick up on this and perhaps reward us with a higher ranking.
Not sure if this could work (or even backfire) but is there someone out there who has already tried this and is willing to share his or her experiences with us (and perhaps some coding on how to do this)?
-
Re: Image Handler 2 Support
Oh, ok. I have that installed.
But the thing is that I like the hoover image better, Because it forces the image to be larger instead of a click.
I have tried to get "Click To Enlarge" to appear under the image, But I cant figure out how to do that.
http://www.allforyourwedding.com/~no...oducts_id=1883
Click Options to see what I mean.
Those option images are just to small.
-
Re: Image Handler 2 Support
Quote:
Originally Posted by
milobloom
Oh, ok. I have that installed.
But the thing is that I like the hoover image better, Because it forces the image to be larger instead of a click.
I have tried to get "Click To Enlarge" to appear under the image, But I cant figure out how to do that.
http://www.allforyourwedding.com/~no...oducts_id=1883
Click Options to see what I mean.
Those option images are just to small.
Hi milobloom jut wondering how did you achieve the tab pages in product info page?
Did you use a separate mod for that puppose?
marksu
-
Re: Image Handler 2 Support
Quote:
Originally Posted by
davale
Would it be possible/useful to incorporate the manufacturers name and/or product name into the filenames IH generates within the bmz_cache directory? I'm asking because I was wondering if this could have an affect with regard to SEO.
Maybe if IH could rewrite a path like
bmz_cache/d/d8418ec3b6e231502512ada44ec5ed62.image.135x89.JPG
to (for example)
bmz_cache/d/d8418ec3b6e231502512ada44ec5ed62.microsoft.image.135x89.JPG
or
bmz_cache/d/d8418ec3b6e231502512ada44ec5ed62.microsoft.vista.image.135x89.JPG
searchengines would pick up on this and perhaps reward us with a higher ranking.
Not sure if this could work (or even backfire) but is there someone out there who has already tried this and is willing to share his or her experiences with us (and perhaps some coding on how to do this)?
Pointless IMO.
Quote:
Originally Posted by
marksu
Hi milobloom jut wondering how did you achieve the tab pages in product info page?
Did you use a separate mod for that puppose?
marksu
Try this one:
http://www.zen-cart.com/index.php?ma...roducts_id=146
-
Re: Image Handler 2 Support
Quote:
Originally Posted by
testuser
Looks interesting, thanks testuser.
-
Re: Image Handler 2 Support
Hello testuser,
There seems to have a frenzy of issues; I sympathize, but I have a question.
I fired up a fresh 1.3.8a and installed the IH2 for 1.3.7, and for the most part it works.
I'm dealing with images that I have to copy from another site. I have to believe that they've been optimized and are as good as they are going to get. Due to the items themsleves, the image sizes are a mixed bag. I've been copying them directly into images/products/*.png
Then selecting them when I add the products to the catalog.
The small images do zoom when I hover over them, but only if the small image size set admin>configuration>images is set to (width x height) (100x80). If I change one of these parameters the zooming stops.
Any insight on why this would be the case?
I can't seem to get it to display larger thumbs on the product list, since I can't change the small image size.
-
Re: Image Handler 2 Support
Quote:
Originally Posted by
Zinfandel
The small images do zoom when I hover over them, but only if the small image size set admin>configuration>images is set to (width x height) (100x80). If I change one of these parameters the zooming stops.
Have you tried using odd numbers --> 101x81, 125x105 ?
This is what I had to do but I know of others that had to use even numbers.
M
-
Re: Image Handler 2 Support
Quote:
Originally Posted by
Zinfandel
Hello testuser,
There seems to have a frenzy of issues; I sympathize, but I have a question.
I fired up a fresh 1.3.8a and installed the IH2 for 1.3.7, and for the most part it works.
I'm dealing with images that I have to copy from another site. I have to believe that they've been optimized and are as good as they are going to get. Due to the items themsleves, the image sizes are a mixed bag. I've been copying them directly into images/products/*.png
Then selecting them when I add the products to the catalog.
The small images do zoom when I hover over them, but only if the small image size set admin>configuration>images is set to (width x height) (100x80). If I change one of these parameters the zooming stops.
Any insight on why this would be the case?
I can't seem to get it to display larger thumbs on the product list, since I can't change the small image size.
In order for the zoom to work, the dimensions of that image would need to match the small dimensions.
http://www.zen-cart.com/forum/showpo...postcount=2036
-
Re: Image Handler 2 Support
I've got a few items in the cart that are named similarly, and since installing image handler, it's putting the recommended matching items below the initial product image. Problem is, it's using a huge image below it.
See here
http://www.zyliedesigns.com/index.ph...roducts_id=190
How can I adjust this to either make it use the thumbnail image, or remove it entirely?
-
Re: Image Handler 2 Support
Quote:
Originally Posted by
shelshell
I've got a few items in the cart that are named similarly, and since installing image handler, it's putting the recommended matching items below the initial product image. Problem is, it's using a huge image below it.
See here
http://www.zyliedesigns.com/index.ph...roducts_id=190
How can I adjust this to either make it use the thumbnail image, or remove it entirely?
It's not IH it's Zen.
Zen looks for additional images that match the suffix of your product image, which in your case they're probably the same for each product.
So if you have two product images, each for different products:
Quote:
product_wood.gif
product_hammer.gif
Zen will actually think the above is an additional image and the other the product image.
To fix it, rename you images like:
Quote:
productwood.gif
producthammer.gif
Then respectively your additional images would look like so:
Quote:
productwood_01.gif
producthammer_01.gif
-
Re: Image Handler 2 Support
Quote:
Originally Posted by
testuser
Zen looks for additional images that match the suffix of your product image, which in your case they're probably the same for each product.
This is in the right direction, but not quite right.
Zen Cart actually looks for image files that extend the basename of a product's main image file and treats them as additional images. The basename is the bit with the filetype extension removed. e.g. the basename for teeshirt.jpg is teeshirt. Thus teeshirt1.jpg, teeshirt_1.jpg and teeshirt_front.jpg would all be treated as additional images. In fact teeshirt<virtually-anything-at-all>.jpg would be an additional image for this product.
However, product_wood.gif and product_hammer.gif would not be linked, unless there was a product with image product.gif, in which case they would both be treated as additional images for that product.
-
Re: Image Handler 2 Support
Any chance there is a way to get IM2 to set the width of additional images? Never came across this problem until now, and don't want to resize images for every single product. :yuck:
-
1 Attachment(s)
Re: Image Handler 2 Support
I added some products today, and am having all kinds of problems. The add new image area is gone, and sometimes the front-end website doesn't work either - when it tries to load one of todays products. Anyone seen this before (screen shot attached)? Could a corrupt image cause all this trouble?
Also when I click on an image to edit it, nothing happens. (should load up something where the add new image link was).
Most of the other products are ok.
Edit: looking through the generated html source, it looks like its crashing somewhere. So the add new image area is not getting displayed at all.
Here is the last portion of the generated html. Does anyone know what goes on around this point, that may be crashing? I don't know why there isn't anything in the error log.?!
<h2>
Product: #13 Red & Clear Glass Bracelet
Model: DD50
</h2>
<table border="0" width="100%" cellspacing="0" cellpadding="2"><tr><td valign="top">
<table border="0" width="100%" cellspacing="0" cellpadding="2">
<tr class="dataTableHeadingRow">
<td class="dataTableHeadingContent">Image name</td>
<td class="dataTableHeadingContent" align="center">Default size</td>
<td class="dataTableHeadingContent" align="center">Medium size</td>
<td class="dataTableHeadingContent" align="center">Large size</td>
<td class="dataTableHeadingContent" align="right">Action </td>
</tr>
<tr class="dataTableRow" onmouseover="rowOverEffect(this)" onmouseout="rowOutEffect(this)" onclick="document.location.href='http://www.mysite.com/admin/image_handler.php?products_filter=13&imgName=DD50blue&action=layout_info'">
<td class="dataTableContent">DD50blue</td>
<td class="dataTableContent" align="center" valign="top">
<img src="/bmz_cache/5/55917a6c410350cc7a600a48d3ed39a3.image.50x33.jpg" border="0" alt="" width="50" height="33"><br /> 100x66<br /><strong>3.05Kb</strong> </td>
<td class="dataTableContent" align="center" valign="top">
<img src="/bmz_cache/0/0f20758bfccefd275f39a0d3b4457ad0.image.50x33.jpg" border="0" alt="" width="50" height="33"><br />150x99<br /><strong>5.23Kb</strong><br /> </td>
<td class="dataTableContent" align="center" valign="top">
<img src="/bmz_cache/b/bdd4b7e5971d12da310819a58f09ad1d.image.50x33.jpg" border="0" alt="" width="50" height="33"><br />598x396<br /><strong>129.83Kb</strong><br /> </td>
<td class="dataTableContent" align="right"><a href="http://www.mysite.com/admin/image_handler.php?products_filter=13&imgName=DD50blue&action=layout_info"><img src="images/icon_info.gif" border="0" alt="Info" title=" Info "></a> </td>
</tr>
-
Re: Image Handler 2 Support
That's weird I've been having problems today to. Keep getting a Warning: imagejpeg() [function.imagejpeg]: Unable to open /public_html/store/bmz_cache/6/6f5a36bd410398a73a30351ba41c5b09.image.70x98.jpg' for writing: Permission denied in /store/includes/classes/bmz_image_handler.class.php
But everything on the front end shows up fine. Just getting the error in Admin. I don't even know what that 70x98 image is. I have no images that size... Tried reinstalling too, didn't work.
This happened after trying to replace existing pictures with updated ones on one product.
-
Re: Image Handler 2 Support
Ok, I've found where the problem is, its in the loop starting on line 719 of admin/image_handler.php. Its making it through the first loop, but then crashing (with no errors or warnings, man I love php) on the second iteration.
The image is valid, I pulled it off the server and am able to view it. But when PHP or ImageHandler tries to do something with it, it bombs.
I believe this is the line its crashing on: $tmp_image_file = $tmp_image->get_local();
Any ideas how to fix?
-
Re: Image Handler 2 Support
I fixed it! The problem was the PHP script was running out of memory. I bumped up the max memory in my php.ini file from 16M to 48M.
It would be nice if this could be avoided - maybe Image Handler could look at what the max memory setting is, then guestimate the largest image that can be processed with that setting. If a larger image is attempted to be loaded - exit with an error.
Is there any other issue with very large images? They aren't resized all the time are they? Just once and then used from the bmz_cache area?
One of the reasons we wanted to use something like Image Handler was so we could just use images straight from the camera without having to worry about resizing. But that does take up space on the webhost. It would be great if the original image could be resized automatically...
-
Re: Image Handler 2 Support
Quote:
That's weird I've been having problems today to. Keep getting a Warning: imagejpeg() [function.imagejpeg]: Unable to open /public_html/store/bmz_cache/6/6f5a36bd410398a73a30351ba41c5b09.image.70x98.jpg' for writing: Permission denied in /store/includes/classes/bmz_image_handler.class.php
But everything on the front end shows up fine. Just getting the error in Admin. I don't even know what that 70x98 image is. I have no images that size... Tried reinstalling too, didn't work.
This happened after trying to replace existing pictures with updated ones on one product.
So, I still can't get this fixed. Kept trying to reset the file permissions, but then I see that it says "could not change permissions. operation not allowed"
Driving me nuts!
-
Re: Image Handler 2 Support
I've searched through the forum for the answer to this and only found the question...a lot...but no answer. I can't read through 226 pages for this answer...someone please help me figure out why my additional images are not showing up.
I've read it could be a naming problem. Can't find where they mention how its supposed to be named but these are:
scrappycats_familyis_preview.jpg
scrappycats_familyis_preview_01.jpg
scrappycats_familyis_preview_02.jpg
I've also read that it could be the additional images setting is off. Can't find this setting.
Under admin in IH2 I only have the following options:
Remove Image Handler from database
Clear image cache
Scan for old IH 0.x and 1.x original images
We have just begun uploading products and extra images are very important to our store so I hope we can get this figured out.
Thanks to anyone who helps!
-
Re: Image Handler 2 Support
-
Re: Image Handler 2 Support
Scratch that. It was working but in admin I got an error on that file and white pages in the store.
-
Re: Image Handler 2 Support
Quote:
Originally Posted by
NicholeAnn
Scratch that. It was working but in admin I got an error on that file and white pages in the store.
:lookaroun Whoa ... calm down. Let's get me up to speed with what's going on. What's the problem your CURRENTLY having - you've posted so many.
-
Re: Image Handler 2 Support
Quote:
Originally Posted by
testuser
actually I stumbled on this guys newest version
http://zen-cart.com/forum/showthread.php?t=86201&page=5
looks very cool.
-
Re: Image Handler 2 Support
I can't seem to find an answer. I'm trying to get rid of the last validation error and I believe it's related to IH2.
The error i'm getting says:
"<" + "/" + letter not allowed here
and references this code:
document.write('<a href="javascript:popupWindow(\'http://www.customcreationsunlimited.com/shop/index.php?main_page=popup_image&pID=896\')"><img src="images/prod/wooden-puzzle-dad.gif" alt="I Love Dad Wooden Puzzle" title=" I Love Dad Wooden Puzzle " width="144" height="120" /><br /><span class="imgLink">larger image</span></a>');
If I'm understanding it correctly, it should end with <\/span><\/a>
Is that correct? What file do I edit to fix it?
URL if it helps; http://www.customcreationsunlimited....uzzle-896.html
-
Re: Image Handler 2 Support
hi All
I have installed image handler 2 to my clients website but for the additional images in each product , when rollover with my mouse the hover image displays correctly , but when i click on that additional image. It only display the main product image and not the image that is being selected
eg:
http://www.trustytime88.com/index.ph...7a619a0a1ca867
Any help is appreciated
-
Re: Image Handler 2 Support
Working on localhost I have installed IH2 v 1.3.7 onto a fresh copy of ZC v1.3.8a
I notice no problems until I attempted to add a new product the other day. That product image would not display on the product list, and it would not display on product info page either. It causes strange behaviour only solved by deleting the product.
For the product info page, sometimes I would see this:
<!--document.write('
where the product image and info were suppose to be, but were never rendered.
And then sometimes I would get the product info but only a link for the pop-up image. The behaviour has been erratic.
I've deleted and reinserted the product numerous times. I deleted the image and recreated it numerous times. But to no avail.
I'm working on a WAMP5 server which is windows based. Does case matter for the image file extensions? Another words, do I have to modify a config file somewhere to allow for uppercase extensions such as .PNG, .JPG, .GIF ??
-
Re: Image Handler 2 Support
I need help. Honestly I do not know where to look into
Site ysandals dot com
Stop working, I do not know what contribution I have added due I have a lot, but IH2 is no longer active.
I did overwrite all the files again, clear cache and set again folder permission to 777.
All started when stop working on product listing per category then I realized that some items on side boxes did not work either, and some yes
also in another site ygfashion dot com, is not working on product listings or Feature Product. If I did set up wrongly of again another contribution may have affected this
Any help would be appreciated.
Thank you
Marcelo
-
Popup pops Under: Re: Image Handler 2 Support
Hey kids,
It's been a month of sundays, but I finally have my cart almost the way I want it. I had everything working on my local testbed, but now that I'm building it on the live server I've hit a snag regarding imagehandler2.
The popup image (for an extra image in the Porduct Info page pops *under* my site images, and way off to one side, like so:
http://kentbarrett.com/zen1/index.ph...&products_id=3
Can't find what I did different from the test site. Any ideas?
TIA!
(ps sorry if I posted this twice, I lost my connection when I was sending this message previously)
-
Re: Popup pops Under: Re: Image Handler 2 Support
Quote:
Originally Posted by
Kent
Hey kids,
It's been a month of sundays, but I finally have my cart almost the way I want it. I had everything working on my local testbed, but now that I'm building it on the live server I've hit a snag regarding imagehandler2.
The popup image (for an extra image in the Porduct Info page pops *under* my site images, and way off to one side, like so:
http://kentbarrett.com/zen1/index.ph...&products_id=3
Can't find what I did different from the test site. Any ideas?
TIA!
(ps sorry if I posted this twice, I lost my connection when I was sending this message previously)
Appears to be working fine ...
-
Re: Popup pops Under: Re: Image Handler 2 Support
Really? Because on Safari and on Firefox (Mac) the rollover popup appears in the top left corner of the page, underneath the logo image.
-
Re: Popup pops Under: Re: Image Handler 2 Support
Quote:
Originally Posted by
Kent
Really? Because on Safari and on Firefox (Mac) the rollover popup appears in the top left corner of the page, underneath the logo image.
Your template does not have correct stylesheet installed for image handler
i.e.
Code:
includes/templates/sang_embed/css/style_imagehover.css
is missing..
-
Re: Image Handler 2 Support
Thanks so much to Focus360. Out of the blue I was getting this error...
Code:
Warning: main() [function.main]: open_basedir restriction in effect.
File(/usr/share/pear/bmz_gif_info.class.php) is not within the allowed path(s):
(/home/httpd/vhosts/freshabundance.com/httpdocs:/tmp) in
/home/httpd/vhosts/freshabundance.com/httpdocs/includes/classes/bmz_image_handler.class.php on line
12
Warning: main(bmz_gif_info.class.php) [function.main]: failed to open stream: Operation
not permitted in
/home/httpd/vhosts/freshabundance.com/httpdocs/includes/classes/bmz_image_handler.class.php on line
12
Fatal error: main() [function.require]: Failed opening required 'bmz_gif_info.class.php'
(include_path='.:/usr/share/pear:.') in
/home/httpd/vhosts/freshabundance.com/httpdocs/includes/classes/bmz_image_handler.class.php on line
12
It literally appeared out of nowhere. I have been running 1.3 since it was released without problems till today.
Found Focus 360's post and that seems to have done the trick.
Has anyone else had this problem appear suddenly?
Quote:
Originally Posted by
focus360
Ok My problem is now sorted!!!
I deleted line 12
require_once('bmz_gif_info.class.php');
and replaced it with the contents of bmz_gif_info.class.php
Everything now works!!!! Including all IH.
So why does the script use require_once('bmz_gif_info.class.php');???
No other scripts in includes/classes call a script.
Ive found nothing which is missing, zoom, compression, and watermarks all work.
:D
-
Re: Image Handler 2 Support
Quote:
Originally Posted by
jacque427
Thanks so much to Focus360. Out of the blue I was getting this error...
Code:
Warning: main() [function.main]: open_basedir restriction in effect.
File(/usr/share/pear/bmz_gif_info.class.php) is not within the allowed path(s):
(/home/httpd/vhosts/freshabundance.com/httpdocs:/tmp) in
/home/httpd/vhosts/freshabundance.com/httpdocs/includes/classes/bmz_image_handler.class.php on line
12
Warning: main(bmz_gif_info.class.php) [function.main]: failed to open stream: Operation
not permitted in
/home/httpd/vhosts/freshabundance.com/httpdocs/includes/classes/bmz_image_handler.class.php on line
12
Fatal error: main() [function.require]: Failed opening required 'bmz_gif_info.class.php'
(include_path='.:/usr/share/pear:.') in
/home/httpd/vhosts/freshabundance.com/httpdocs/includes/classes/bmz_image_handler.class.php on line
12
It literally appeared out of nowhere. I have been running 1.3 since it was released without problems till today.
Found Focus 360's post and that seems to have done the trick.
Has anyone else had this problem appear suddenly?
Path bug...
-
Re: Image Handler 2 Support
If instead of safe_mode, you set an open_basedir directory then all file operations will be limited to files under the specified directory. .....
----perhaps host has set new restrictions----
Quote:
Warning: main() [function.main]: open_basedir restriction in effect..
-
Re: Image Handler 2 Support
My new site has Image Handler2 install and was working OK till I installed Zen lightbox v1.4. Zen lightbox works OK but not Image Handler2.
I have looked for help in the forum but not yet found a fix.
Please help
My new site http://www.indigosilvergems.com
-
Re: Image Handler 2 Support
Jatocar,
Your problem sounds fairly common. If you haven't seen that here then you haven't looked all that hard.
There is most likely a file that these two mods share in common.
By installing the Litebox, you most likely negated the modification made to that file by IH2.
When this happens, you have to merge the changes into a single version as opposed to blindly uploading the file.
Go back and trace over your steps to see if this is the case, if you find a common file that both mods have modified, pick one version and then merge in the changes from the other one.
Let us know how that goes for you.
-
Re: Image Handler 2 Support
These are possibly two files from ZenLight Box that you might want to compare to IH2 if IH2 uses these files as well.
\includes\templates\YOUR-TEMPLATE-FOLDER\templatestpl_modules_main_product_image.php
\includes\modules\YOUR-TEMPLATE-FOLDER\additional_images.php
IH2 and Zen Litebox works fine. You can see it on our site. To see additional images in effect search for CSGFT0004.
-
Re: Image Handler 2 Support
Quote:
Originally Posted by
BlessIsaacola
These are possibly two files from ZenLight Box that you might want to compare to IH2 if IH2 uses these files as well.
\includes\templates\YOUR-TEMPLATE-FOLDER\templatestpl_modules_main_product_image.php
\includes\modules\YOUR-TEMPLATE-FOLDER\additional_images.php
IH2 and Zen Litebox works fine. You can see it on our site. To see additional images in effect search for CSGFT0004.
Thanks for your info, will it be easier for me to reinstall IH2 as I am new to Zen cart and not yet know my way round.
Is a more detail fix available to dig me out this one?
Thanks:smile:
-
Re: Image Handler 2 Support
Hi,
I'm having an annoying little problem. IH is working great for me on the front end, but a lot of the product images on the backend are broken. The reason why the images are broken is that IH is giving the wrong relative URL.
My site is at www.domain.com/new/, but IH is saying that the relative URLs for the images on the backend are at /new//new/index.php instead of /new/index.php
Anybody have any idea how to change this?
Thanks a lot,
Luke
-
Re: Image Handler 2 Support
Hi,
Can anyone tell me is the latest version of IH2 (updated oct 2007 in download section) compatible with zen cart 1.3.8a, there seems to be a lot of differences in the admin/includes/modules/catagory_product_listing.php file
-
Re: Image Handler 2 Support
Quote:
Originally Posted by
Jatocar
Thanks for your info, will it be easier for me to reinstall IH2 as I am new to Zen cart and not yet know my way round.
Is a more detail fix available to dig me out this one?
Thanks:smile:
Whether you reinstall or keep your current installation, the key is to use a file compare tool like winmerge or beyond and compare to make sure that you incorporate changes that you need into the file that is shared by both. I am going to be installing this on test site soon, if you're still having problem, I will post the changes here.
-
Re: Image Handler 2 Support
Quote:
Originally Posted by
Jatocar
Thanks for your info, will it be easier for me to reinstall IH2 as I am new to Zen cart and not yet know my way round.
Is a more detail fix available to dig me out this one?
Thanks:smile:
Okay, I just checked our production installation. The file that they both shared is \includes\modules\YOUR-TEMPLATE-FOLDER\additional_images.php
Both IH2 and Zen Lightbox touches this file so you want to merge the changes.
Pasted below is the file in my override folder.
PHP Code:
<?php
/**
* additional_images module
*
* Prepares list of additional product images to be displayed in template
*
* @package templateSystem
* @copyright Copyright 2003-2006 Zen Cart Development Team
* @copyright Portions Copyright 2003 osCommerce
* @license http://www.zen-cart.com/license/2_0.txt GNU Public License V2.0
* @version $Id: additional_images.php 5369 2006-12-23 10:55:52Z drbyte $
*/
if (!defined('IS_ADMIN_FLAG')) {
die('Illegal Access');
}
if (!defined('IMAGE_ADDITIONAL_DISPLAY_LINK_EVEN_WHEN_NO_LARGE')) define('IMAGE_ADDITIONAL_DISPLAY_LINK_EVEN_WHEN_NO_LARGE','Yes');
$images_array = array();
if ($products_image != '') {
// prepare image name
$products_image_extension = substr($products_image, strrpos($products_image, '.'));
$products_image_base = ereg_replace($products_image_extension . '$', '', $products_image);
// if in a subdirectory
if (strrpos($products_image, '/')) {
$products_image_match = substr($products_image, strrpos($products_image, '/')+1);
//echo 'TEST 1: I match ' . $products_image_match . ' - ' . $file . ' - base ' . $products_image_base . '<br>';
$products_image_match = ereg_replace($products_image_extension, '', $products_image_match) . '_';
$products_image_base = $products_image_match;
}
$products_image_directory = ereg_replace($products_image, '', substr($products_image, strrpos($products_image, '/')));
if ($products_image_directory != '') {
$products_image_directory = DIR_WS_IMAGES . ereg_replace($products_image_directory, '', $products_image) . "/";
} else {
$products_image_directory = DIR_WS_IMAGES;
}
// Check for additional matching images
$file_extension = $products_image_extension;
$products_image_match_array = array();
if ($dir = @dir($products_image_directory)) {
while ($file = $dir->read()) {
if (!is_dir($products_image_directory . $file)) {
if(preg_match("/" . $products_image_base . "/i", $file) == '1') {
if (substr($file, 0, strrpos($file, '.')) != substr($products_image, 0, strrpos($products_image, '.'))) {
if ($products_image_base . ereg_replace($products_image_base, '', $file) == $file) {
//echo 'I AM A MATCH ' . $file . '<br />';
$images_array[] = $file;
} else {
//echo 'I AM NOT A MATCH ' . $file . '<br />';
}
}
}
}
}
if (sizeof($images_array)) {
sort($images_array);
}
$dir->close();
}
}
// Build output based on images found
$num_images = sizeof($images_array);
$list_box_contents = '';
$title = '';
if ($num_images) {
$row = 0;
$col = 0;
if ($num_images < IMAGES_AUTO_ADDED || IMAGES_AUTO_ADDED == 0 ) {
$col_width = floor(100/$num_images);
} else {
$col_width = floor(100/IMAGES_AUTO_ADDED);
}
for ($i=0, $n=$num_images; $i<$n; $i++) {
$file = $images_array[$i];
$file_extension = substr($file, strrpos($file, '.'));
$products_image_large = ereg_replace('^' . DIR_WS_IMAGES, DIR_WS_IMAGES . 'large/', $products_image_directory) . ereg_replace($file_extension . '$', '', $file) . IMAGE_SUFFIX_LARGE . $file_extension;
$flag_has_large = true;
$flag_display_large = (IMAGE_ADDITIONAL_DISPLAY_LINK_EVEN_WHEN_NO_LARGE == 'Yes' || $flag_has_large);
$base_image = $products_image_directory . $file;
$thumb_slashes = zen_image($base_image, addslashes($products_name), SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT);
// remove additional single quotes from image attributes (important!)
$thumb_slashes = preg_replace("/([^\\\\])'/", '$1\\\'', $thumb_slashes);
$thumb_regular = zen_image($base_image, $products_name, SMALL_IMAGE_WIDTH, SMALL_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:
// bof Zen Lightbox v1.4 aclarke 2007-09-22
if (ZEN_LIGHTBOX_STATUS == 'true') {
$script_link = '<script language="javascript" type="text/javascript"><!--' . "\n" . 'document.write(\'' . ($flag_display_large ? '<a href="' . zen_lightbox($products_image_large, addslashes($products_name), LARGE_IMAGE_WIDTH, LARGE_IMAGE_HEIGHT) . '" rel="lightbox[gallery]" title="' . addslashes($products_name) . '">' . $thumb_slashes . '<br />' . TEXT_CLICK_TO_ENLARGE . '</a>' : $thumb_slashes) . '\');' . "\n" . '//--></script>';
} else {
$script_link = '<script language="javascript" type="text/javascript"><!--' . "\n" . 'document.write(\'' . ($flag_display_large ? '<a href="javascript:popupWindow(\\\'' . $large_link . '\\\')">' . $thumb_slashes . '<br />' . TEXT_CLICK_TO_ENLARGE . '</a>' : $thumb_slashes) . '\');' . "\n" . '//--></script>';
}
// eof Zen Lightbox v1.4 aclarke 2007-09-22
$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">' . TEXT_CLICK_TO_ENLARGE . '</span></a>' : $thumb_regular ) . '</noscript>';
// $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 = $script_link . "\n " . $noscript_link;
// $link = $alternate_link;
// List Box array generation:
$list_box_contents[$row][$col] = array('params' => 'class="additionalImages centeredContent back"' . ' ' . 'style="width:' . $col_width . '%;"',
'text' => "\n " . $link);
$col ++;
if ($col > (IMAGES_AUTO_ADDED -1)) {
$col = 0;
$row ++;
}
} // end for loop
} // endif
?>
-
Re: Image Handler 2 Support
Quote:
Originally Posted by
Phil020782
Hi,
Can anyone tell me is the latest version of IH2 (updated oct 2007 in download section) compatible with zen cart 1.3.8a, there seems to be a lot of differences in the admin/includes/modules/catagory_product_listing.php file
It's compatible as long as you use a file compare to merge the changes.
-
Re: Image Handler 2 Support
Quote:
Originally Posted by
BlessIsaacola
Okay, I just checked our production installation. The file that they both shared is \includes\modules\YOUR-TEMPLATE-FOLDER\additional_images.php
Both IH2 and Zen Lightbox touches this file so you want to merge the changes.
Pasted below is the file in my override folder.
PHP Code:
<?php
/**
* additional_images module
*
* Prepares list of additional product images to be displayed in template
*
* @package templateSystem
* @copyright Copyright 2003-2006 Zen Cart Development Team
* @copyright Portions Copyright 2003 osCommerce
* @license http://www.zen-cart.com/license/2_0.txt GNU Public License V2.0
* @version $Id: additional_images.php 5369 2006-12-23 10:55:52Z drbyte $
*/
if (!defined('IS_ADMIN_FLAG')) {
die('Illegal Access');
}
if (!defined('IMAGE_ADDITIONAL_DISPLAY_LINK_EVEN_WHEN_NO_LARGE')) define('IMAGE_ADDITIONAL_DISPLAY_LINK_EVEN_WHEN_NO_LARGE','Yes');
$images_array = array();
if ($products_image != '') {
// prepare image name
$products_image_extension = substr($products_image, strrpos($products_image, '.'));
$products_image_base = ereg_replace($products_image_extension . '$', '', $products_image);
// if in a subdirectory
if (strrpos($products_image, '/')) {
$products_image_match = substr($products_image, strrpos($products_image, '/')+1);
//echo 'TEST 1: I match ' . $products_image_match . ' - ' . $file . ' - base ' . $products_image_base . '<br>';
$products_image_match = ereg_replace($products_image_extension, '', $products_image_match) . '_';
$products_image_base = $products_image_match;
}
$products_image_directory = ereg_replace($products_image, '', substr($products_image, strrpos($products_image, '/')));
if ($products_image_directory != '') {
$products_image_directory = DIR_WS_IMAGES . ereg_replace($products_image_directory, '', $products_image) . "/";
} else {
$products_image_directory = DIR_WS_IMAGES;
}
// Check for additional matching images
$file_extension = $products_image_extension;
$products_image_match_array = array();
if ($dir = @dir($products_image_directory)) {
while ($file = $dir->read()) {
if (!is_dir($products_image_directory . $file)) {
if(preg_match("/" . $products_image_base . "/i", $file) == '1') {
if (substr($file, 0, strrpos($file, '.')) != substr($products_image, 0, strrpos($products_image, '.'))) {
if ($products_image_base . ereg_replace($products_image_base, '', $file) == $file) {
//echo 'I AM A MATCH ' . $file . '<br />';
$images_array[] = $file;
} else {
//echo 'I AM NOT A MATCH ' . $file . '<br />';
}
}
}
}
}
if (sizeof($images_array)) {
sort($images_array);
}
$dir->close();
}
}
// Build output based on images found
$num_images = sizeof($images_array);
$list_box_contents = '';
$title = '';
if ($num_images) {
$row = 0;
$col = 0;
if ($num_images < IMAGES_AUTO_ADDED || IMAGES_AUTO_ADDED == 0 ) {
$col_width = floor(100/$num_images);
} else {
$col_width = floor(100/IMAGES_AUTO_ADDED);
}
for ($i=0, $n=$num_images; $i<$n; $i++) {
$file = $images_array[$i];
$file_extension = substr($file, strrpos($file, '.'));
$products_image_large = ereg_replace('^' . DIR_WS_IMAGES, DIR_WS_IMAGES . 'large/', $products_image_directory) . ereg_replace($file_extension . '$', '', $file) . IMAGE_SUFFIX_LARGE . $file_extension;
$flag_has_large = true;
$flag_display_large = (IMAGE_ADDITIONAL_DISPLAY_LINK_EVEN_WHEN_NO_LARGE == 'Yes' || $flag_has_large);
$base_image = $products_image_directory . $file;
$thumb_slashes = zen_image($base_image, addslashes($products_name), SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT);
// remove additional single quotes from image attributes (important!)
$thumb_slashes = preg_replace("/([^\\\\])'/", '$1\\\'', $thumb_slashes);
$thumb_regular = zen_image($base_image, $products_name, SMALL_IMAGE_WIDTH, SMALL_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:
// bof Zen Lightbox v1.4 aclarke 2007-09-22
if (ZEN_LIGHTBOX_STATUS == 'true') {
$script_link = '<script language="javascript" type="text/javascript"><!--' . "\n" . 'document.write(\'' . ($flag_display_large ? '<a href="' . zen_lightbox($products_image_large, addslashes($products_name), LARGE_IMAGE_WIDTH, LARGE_IMAGE_HEIGHT) . '" rel="lightbox[gallery]" title="' . addslashes($products_name) . '">' . $thumb_slashes . '<br />' . TEXT_CLICK_TO_ENLARGE . '</a>' : $thumb_slashes) . '\');' . "\n" . '//--></script>';
} else {
$script_link = '<script language="javascript" type="text/javascript"><!--' . "\n" . 'document.write(\'' . ($flag_display_large ? '<a href="javascript:popupWindow(\\\'' . $large_link . '\\\')">' . $thumb_slashes . '<br />' . TEXT_CLICK_TO_ENLARGE . '</a>' : $thumb_slashes) . '\');' . "\n" . '//--></script>';
}
// eof Zen Lightbox v1.4 aclarke 2007-09-22
$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">' . TEXT_CLICK_TO_ENLARGE . '</span></a>' : $thumb_regular ) . '</noscript>';
// $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 = $script_link . "\n " . $noscript_link;
// $link = $alternate_link;
// List Box array generation:
$list_box_contents[$row][$col] = array('params' => 'class="additionalImages centeredContent back"' . ' ' . 'style="width:' . $col_width . '%;"',
'text' => "\n " . $link);
$col ++;
if ($col > (IMAGES_AUTO_ADDED -1)) {
$col = 0;
$row ++;
}
} // end for loop
} // endif
?>
Thanks, lots of info for me to deal, you would think these 2 programs IH2 and zen lightbox can be install and work without this sort of problems. I am not sure how to solve the problem with the info you have provided.
More help required please.
-
Re: Image Handler 2 Support
Copy the code I pasted and save it as additional_images.php and then compare it to your file to see what's different. Like I said, it works just fine on our site.
Assuming you're using override, the file you want to compare to is located at:
\includes\modules\YOUR-TEMPLATE-FOLDER\additional_images.php
Again, I am assuming that everything else is working fine except for additional image.
-
Re: Image Handler 2 Support
Quote:
Originally Posted by
lukemcr
Hi,
I'm having an annoying little problem. IH is working great for me on the front end, but a lot of the product images on the backend are broken. The reason why the images are broken is that IH is giving the wrong relative URL.
My site is at
www.domain.com/new/, but IH is saying that the relative URLs for the images on the backend are at /new//new/index.php instead of /new/index.php
Anybody have any idea how to change this?
Thanks a lot,
Luke
So, any ideas?
-
Re: Image Handler 2 Support
Quote:
Originally Posted by
Jatocar
Thanks, lots of info for me to deal, you would think these 2 programs IH2 and zen lightbox can be install and work without this sort of problems. I am not sure how to solve the problem with the info you have provided.
More help required please.
Tried your info still can't get IH2 to work.
Any other options????
Thanks
-
Re: Image Handler 2 Support
Been using 1.3.7 very happily. PLanning to upgrade soon. The store runs smooth so I haven't needed to roll up my sleeves for several months. My holiday is over.
1. Noticed a few Category images were not showing.
2. Cleared bmz_cache and lost 25% of my category images.
3. View source and missing Cat images says something like: bmz_cache/a/a896d5f859e244349d82ed5a7d755ffb.image.99x57.png
When I look on the server, the above file is there BUT it is empty. 0Kb
4. Delete the above image from the server and get this error once:
Code:
Warning: imagepng() [function.imagepng]: gd-png: fatal libpng error: zlib error in /home/musicpla/public_html/catalogue/includes/classes/bmz_image_handler.class.php on line 646
Warning: imagepng() [function.imagepng]: gd-png error: setjmp returns error condition in /home/musicpla/public_html/catalogue/includes/classes/bmz_image_handler.class.php on line 646
5. Refresh screen. Error is gone but another 0Kb image with the SAME name is is produced in it's place.
To my limited understanding it looks like IH2 doesn't have permissions to create new images however, I can add new product no with problem.
Any ideas?
Rob
-
Re: Image Handler 2 Support
Quote:
Originally Posted by
AndyII
If instead of
safe_mode, you set an
open_basedir directory then all file operations will be limited to files under the specified directory. .....
----perhaps host has set new restrictions----
It was the host, the upgraded a control panel.
Thanks for the replies.
-
Re: Image Handler 2 Support
Hi BlessIsaacola
I have installed a new template Cherry Zen which works OK apart from IH2 as you can see here at http://www.indigosilvergems.com.
I still can't get IH2 to work on this template either or the Classic Contemporary Green, I have reinstall IH2 to both templates as in the readme file.
When I sign up to my hosting company for my Zen Cart site they had installed their own template which works with IH2 and Zen Lightbox OK.
I can't understand why it won't work with the other 2 templates.
Help Please ..... what have I done wrong.
:(
-
Re: Image Handler 2 Support
Code:
includes/templates/template_default/jscript/jscript_imagehover.js
Do you have the file above installed.. not showing as available
when your website loads.
-
Re: Image Handler 2 Support
Quote:
Originally Posted by
misty
Code:
includes/templates/template_default/jscript/jscript_imagehover.js
Do you have the file above installed.. not showing as available
when your website loads.
Hi misty
The file above was installed OK.
Good news...... I've now got IH2 working with Zen lightbox here how, these 3 files listed below were missing from these 2 template folders /includes/templates/cherry_zen/jscript/ and /includes/templates/classic/jscript/.
I copy these files into the above folders all working OK.
jscript_imagehover.js
loadNodes.js
treeview.js
Thanks for pointing me in the general direction.
:clap::D
-
Re: Image Handler 2 Support
Is it possible to make the additional images smaller on the product info page?
Cal
-
Re: Image Handler 2 Support
having the same problem
Quote:
images are broken is that IH is giving the wrong relative URL.
My site is at
www.domain.com/new/, but IH is saying that the relative URLs for the images on the backend are at /new//new/index.php instead of /new/index.php
tried the merging of:
\includes\modules\YOUR-TEMPLATE-FOLDER\additional_images.php
to no avail
Also, if i am in the Image Handler 2 MANAGER and click NEW FILE under "Click to add a new image to this product" i simply get shot to the ADMIN part of the mod
i am assuming this is a 1.3.8 issue, as it works fine on the same templates ina a 1.3.7 setup
any help appreciated
-
Re: Image Handler 2 Support
I installed a program to rewrite my URLs and now none of my image are showing. I need to use absolute URLs. How can I modify image handler to do this?
Thanks.
-
Re: Image Handler 2 Support
Hm, interesting. I'm glad I'm not the only person having this problem. It's not a deal-breaker, of course, but it'd be nice to be able to fix it. :-)
-
Re: Image Handler 2 Support
Quote:
Originally Posted by
nsirago
I installed a program to rewrite my URLs and now none of my image are showing. I need to use absolute URLs. How can I modify image handler to do this?
Thanks.
Quote:
Originally Posted by
lukemcr
Hm, interesting. I'm glad I'm not the only person having this problem. It's not a deal-breaker, of course, but it'd be nice to be able to fix it. :-)
There's a ton of ways to fix the problem your having, but none of them will help unless we know which rewrite program your using.
And what if we made the URL Rewrite program leave out images, instead of modifying Image Handler?
Zen Cart 1.3.8?
-
Re: Image Handler 2 Support
Well, I'm having a similar problem only in the sense that none of my images are showing up in the admin. I don't know if nsirago's images weren't showing up only in the admin or on the frontend too.
I'm using 1.3.8. It doesn't have any significant modifications to it. My URLS are not being re-written. (mod_rewrite is installed on the server, but not being called from the .htaccess, and no URL rewriting module is installed.)
My problem is that one of the relative URLs within IH2's admin has some duplicate content. That's why image URLs within the admin show up as /new//new/image/, where my site is at www.domain.com/new/
-
Re: Image Handler 2 Support
Quote:
Originally Posted by
wasana
and one more question...
any way to keep animated gif's working for product images?
yes, I know they are so 90's but I've got one image that works great for what I need but IH stops the animation... I tried deleting in IH2 manager and loading it via ZC categories/products but IH2 still controls it (hover)
ideas....
:yes:
I've searched this thread until the present and haven't been able to find an answer to wasana's query. I'm having the same problem now. The customer wanted animated images (like this :yes: )in the category headings and they stopped working after I installed IH2. Doe anyone know if there has been a resolution of this problem since wasana's post in 2006?
-
Image Handler 2 Support: Upgrading IH2
I wanted to install IH2, and so figured I would download the contribution directly from the BreakMyZenCart website, thinking I would be assured of getting the most current version.
As it turns out, the BMZC site apparently isn't maintained, so I ended up installing the older IH2 v 1.3. I've since found IH2 v1.3.7 in the Zen Cart contribution area. I've performed a reinstall, having gone through all the folders, and restoring the original Zen Cart files, where appropriate.
Following the original v1.3 install, there was an "Install" link within the Zen Cart admin Tools, to complete the installation. I assume to run a script to modify the MySQL database. This was not an option after pushing out the new v1.3.7 version.
Does anyone know if there are any database changes that occurred between v1.3 and v1.3.7, or should I be good as is?
IH2 seems to be operational within Zen Cart admin (Source Image Preview now works, which previously did not with v1.3), but I have not yet used it with live data.
Thanks in advance.
DBB1
-
Re: Image Handler 2 Support: Upgrading IH2
Quote:
Originally Posted by
DBB1
I wanted to install IH2, and so figured I would download the contribution directly from the BreakMyZenCart website, thinking I would be assured of getting the most current version.
As it turns out, the BMZC site apparently isn't maintained, so I ended up installing the older IH2 v 1.3. I've since found IH2 v1.3.7 in the Zen Cart contribution area. I've performed a reinstall, having gone through all the folders, and restoring the original Zen Cart files, where appropriate.
Following the original v1.3 install, there was an "Install" link within the Zen Cart admin Tools, to complete the installation. I assume to run a script to modify the MySQL database. This was not an option after pushing out the new v1.3.7 version.
Does anyone know if there are any database changes that occurred between v1.3 and v1.3.7, or should I be good as is?
IH2 seems to be operational within Zen Cart admin (Source Image Preview now works, which previously did not with v1.3), but I have not yet used it with live data.
Thanks in advance.
DBB1
Breakmyzencart has become exactly that. The community has pushed the development of Image Handler into compatibility with the newer versions of Zen Cart, so you should get this mod from Zen's download section.
As far as the install link there's one in the 1.3.7 version of IH, but if you had previously installed IH using an older version it might detect that it's already installed. So from the newer version you installed, un-install the IH data, then re-install it. You can do this from the Admin of your cart.
-
Re: Image Handler 2 Support: Upgrading IH2
Quote:
Originally Posted by
testuser
Breakmyzencart has become exactly that. The community has pushed the development of Image Handler into compatibility with the newer versions of Zen Cart, so you should get this mod from Zen's download section.
As far as the install link there's one in the 1.3.7 version of IH, but if you had previously installed IH using an older version it might detect that it's already installed. So from the newer version you installed, un-install the IH data, then re-install it. You can do this from the Admin of your cart.
Thanks, testuser!
I did as you suggested; very quick and painless. Had I realized that I could have un-installed the data components that simply, I would have done so prior to installing the 1.3.7 version.
But tell me, has anyone resolved the animated gif issue with IH2?
Pardon me if the question has been addressed already. I'm new to the forum, and have tried searching, but I must be missing something, because it seems to be fairly cumbersome to search within threads.
Thanks again,
-DBB1
-
Re: Image Handler 2 Support: Upgrading IH2
Quote:
Originally Posted by
DBB1
Thanks, testuser!
I did as you suggested; very quick and painless. Had I realized that I could have un-installed the data components that simply, I would have done so prior to installing the 1.3.7 version.
But tell me, has anyone resolved the animated gif issue with IH2?
Pardon me if the question has been addressed already. I'm new to the forum, and have tried searching, but I must be missing something, because it seems to be fairly cumbersome to search within threads.
Thanks again,
-DBB1
What's wrong with your animated gif's? They're probably being flattened.