Tagged: Lightbox
Hi guys,
having an issue with the lightbox picking up links that it shouldn’t. For instance here:
https://www.microstockman.com/stock-images/grazing-yak/
the only image that should be displayed in the lightbox on this page is the large main image when clicked. If you click it, it comes up. But it thinks it is one of 5 images on the page. Only problem is, the other 4 things that the lightbox is counting aren’t images at all, but just links on the page such as the License link (if you choose an image size you will see this appear) which looks something like this
https://www.microstockman.com/licensing/#license_smalljpeg
Here is some code: <span>Royalty Free</span>
Why are these links not being excluded from the lightbox? How can I fix it?
Cheers
Hey!
I suppose you’re doing the same for all “Products” throughout the site, if that’s the case then i’d suggest using CSS to fix this issue:
.single-product .mfp-prevent-close {
display: none !important;
}
.single-product .mfp-counter {
display: none !important;
}
The following will hide the arrows and counter in single product lightboxes.
Best regards,
Josue
Hey thanks for that, thats not a bad fix.
Only problem is this link https://www.microstockman.com/licensing/#license_mediumjpeg (which is on every product page) still gets loaded in the lightbox when it is clicked.
Any other suggestions?
Thanks again
Hey!
Try removing “jpeg” from the path.
Regards,
Josue
yep, thats got it. Thanks for that.
You are welcome, glad to help :)
Best regards,
Josue