- Posts: 21
- Thank you received: 0
Magnifying Glass
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
<?php
function hikashop_image_link_render(&$obj,$path,$addpopup,$optionslink,$html){
$html.='ADD YOUR HTML THERE';
return '<a rel="{handler: \'iframe\', size: {x: '.$obj->width.', y: '.$obj->height.'}}" target="_blank" href="'.$obj->uploadFolder_url.$path.'" onclick="SqueezeBox.fromElement(this,{parse: \'rel\'});return false;" '.$optionslink.'>'.$html.'</a>';
}
Please Log in or Create an account to join the conversation.
thanks a lot...i just give it a try and it works fine...just need to finde a better Magnifying Glass...bit this is perfect!
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
but anyway thank you very much...it looks good now and is a good "UI"add to the shop...
take care its friday 9pm here..i finish now..and will have a beer..cheers!
Please Log in or Create an account to join the conversation.
<?php
function hikashop_image_link_render(&$obj,$path,$addpopup,$optionslink,$html){
$html.='<img src="imagesblablabla.png" alt="" width="5" height="5" TOP:35px; LEFT:170px; />';
return '<a rel="{handler: \'iframe\', size: {x: '.$obj->width.', y: '.$obj->height.'}}" target="_blank" href="'.$obj->uploadFolder_url.$path.'" onclick="SqueezeBox.fromElement(this,{parse: \'rel\'});return false;" '.$optionslink.'>'.$html.'</a>';
}
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
That thread is more than 4 years old ; HikaShop have evolve a log since that day and we extracted the display of images from that helper to put a maximum directly in the view (show_block_img).
Regards,
Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
What jerome means is that it is now simpler. You can go in the menu Display>Views, edit the file "show_block_img" and add your img tag in there with custom CSS in order to display your magnifiying glass image on top of the product image. You don't need to know PHP or javascript anymore.
Please Log in or Create an account to join the conversation.
<img src="imagesblablabla.png" alt="" width="5" height="5" TOP:35px; LEFT:170px; />
Please Log in or Create an account to join the conversation.
- Posts: 12953
- Thank you received: 1778
You'll just have to add it on the "show_block_img" file of the "product" view, of your front-ent template via "Hikashop->Display->Views".
Please Log in or Create an account to join the conversation.
<img src="images/blbla.png" alt="Smiley face" height="42" width="42" align="right">
And the image is showing up. But it is below the main image. M i missing something? Adapting the height etc is not working.
Please Log in or Create an account to join the conversation.
Yes, you're missing something. As I said in my first message to you, you need to
So far, you only did half of what I said and only added the img tag. Next, you need to add custom CSS to have your image overflow on top of the main image.add your img tag in there with custom CSS in order to display your magnifying glass image on top of the product image
Please Log in or Create an account to join the conversation.
- go to Hikashop->Display->Views
- click on "show_block_img"
- on line 76 after
insert
where "zoom-img.png" is your img, in that case i just took the magnifying glass image of jcemediabox and put it in "images"
After you can decide where to put exactely your image by adjusting "bottom:5%" and "left:45%"
Please Log in or Create an account to join the conversation.