My Site - Zen Cart & WordPress integration specialist
I don't answer support questions via PM. Post add-on support questions in the support thread. The question & the answer will benefit others with similar issues.
As you are throwing a glass of wine into the discussion i would say that option would always win it in my book hehe...
Just can't get my head around why the code would be a problem for the additional images. I might be tempted to run a default cart in my xampp and see for myself, if i wasn't drinking my last can of beer i would have probably allready done so....ahhh...i should probably go to bed
![]()
It works fine on my test setup,
Set up a wamp server on your local machine, makes testing a heck of a lot easier
I tried similar with html entities but my knowledge of PHP isn't that great,
hence the hack which I knew would work, as expecting people not to use apostrophes in product names is a bit daft really.
Nice to see my hack replaced with some nice correct code
Webzings Design
Semi retired from Web Design
There's ALWAYS wine in the discussion when I'm working from home!
So ladies and gentlemen.. Are we convinced that this is the change that should be made to the code?? If so I'll update the files and submit an update... I'll test too of course, but I trust your findings.. I can simply make the change and submit it without having to test myself..
My Site - Zen Cart & WordPress integration specialist
I don't answer support questions via PM. Post add-on support questions in the support thread. The question & the answer will benefit others with similar issues.
Please make sure you also comment out the fancy quote line so it looks like this when you test it:
second:PHP Code:
//escape possible quotes if they're not already escapped
// $alt = preg_replace("/([^\\\\])'/", '$1\\\'', $alt);
// $alt = str_replace('"', '"', $alt);
//replace apostrophe with fancy quote
//$alt = str_replace("'", "‘", $alt);
$alt = addslashes(htmlentities($alt, ENT_COMPAT, CHARSET));
there is another problem in this function, the filename gets extracted with substr but it is extracted with the / included.
This makes the final path to the hover image have 2 slashes in the path which is incorrect. (you can see it in the page source)
This can be corrected by:
PHP Code:
//old line in this function
//$products_image_filename = substr($src, strrpos($src, '/'), strlen ($src) - strrpos ($src, '/') - strlen ($this->extension));
//corrected
$products_image_filename = substr($src, strrpos($src, '/') + 1, strlen ($src) - (strrpos ($src, '/') + 1) - strlen ($this->extension));
Yes I understand.. I actually will probably just make it a clean inclusion and leave out the old commented out sections altogether.. Seems they are obsolete at this point..
Got it.. will add this to the changes to be made.. (excluding the commented out obsolete sections..)
My Site - Zen Cart & WordPress integration specialist
I don't answer support questions via PM. Post add-on support questions in the support thread. The question & the answer will benefit others with similar issues.
Hi guys, I have very few basic questions regarding that. I luckily installed it on my site and looks like its installed correctly.
But the problem is where I can add additional picture for each product that i have on my website?
I read the IH documentation but it does not tell in detail. anyone has any site where these additional pictures are showing?
I thought it will add additional column in main product page where we can browse another picture from computer?
Can you please help me in this regard,
Thanks
when you go to tools/image handler to get its controls---or click the little pink i in the product listing page you will get the place to add your additional images
they must have the same type of image as the primary one...jpg with jpg--png with png --- gif with gif...no mix and match or the additional ones will not show up.
click the ? and it will give you another window where you will see the main image a bit larger and under it 3 buttons...clck the add image (something like that) button to then browse your computer for the next image for this product.
repeat the add image process with each additional image you wish to add.
I cheat though and upload them all to the server...nameing them as such:
mainimagenameherewithnospaces.jpg
mainimagenameherewithnospaces_01.jpg
mainimagenameherewithnospaces_02.jpg
mainimagenameherewithnospaces_03.jpg
for how ever many you are adding, then in the product page where you put the path for the main image the others will automatically show up when you are through---but you won't see them unless you are in image handler control area or the actual product page in your store.
hope that is what you were asking....head full of flu and meds=brainless
Wanted to add this: for those who don't want to remember HOW to name images so that Zen Cart will recognize them as additional images, if you upload additional images through the IH2 admin controls, IH2 takes care to properly name your additional images so that Zen Cart recognizes them as such..
My Site - Zen Cart & WordPress integration specialist
I don't answer support questions via PM. Post add-on support questions in the support thread. The question & the answer will benefit others with similar issues.
hi i am running latest IH2, digital shop template with zencart 1.3.9h
can someone tell me if it is possible to have a hover image in my subcatagories as here "http://thearmysurplusstore.co.uk/shop/index.php?main_page=index&cPath=7" and also on the product listing here "http://thearmysurplusstore.co.uk/shop/index.php?main_page=index&cPath=7_51" i have seen it on a site.
also since installing ih when you click on a catagory the catagory image becomes fuzzy, how can i solve this?
hope this is all clear and thanks in advance for help.
I've been Zenned
Bookmarks