How do you remove tooltips from images on dynamic pages? Is there code for this, or a workaround?
Yes. You can use code:
$w.onReady( function() {
$w("#dynamicDataset").onReady( () => {
$w("#image1").tooltip = "";
})
})
Perfect code, thank you!
@saratisch2 you’re welcome
Hi J.D.
Is there an alternative code that has the same effect as above? As soon as I use this code the images in my repeater show problems. When on the page the wix stock images appear, have to crtl+f5 to see the correct images… The tooltip is indeed gone but this code does mess up the loading of the images on my repeater. Changing the image tooltip settings to no text or any other text doesn’t work either. Trying to find different code that does the same trick but without messing with the loading of my the images. (Your code does work perfect for me when have single image on page that I want tooltip removed.) Any idea how to make it work for my images in repeater? Thanks!
@dmon This code shouldn’t make any problem. I’ve tested it just now and it worked perfect for me. Try to see if there’s a problem somewhere else in your code.
Hi there,
Im encountering the same issue and have contacted Wix suggesting that issue should be easily be toggled off or on without coding. They have said the only way around it is to use code and i’ve used J.D’s suggested code above.
I dont have any experience with code so i’m not really sure how to identify what im doing wrong. Heres screenshots from what I tried.
Picture 1: Dynamic Page that shows images of Hotels. I want to stop the file type appearing for end users when they hover over the picture. Adding a tooltip name to the picture does nothing.
Picture 2: Added the suggested code above and error indicates that onReady is not a function?
Im probably doing something fundamentally wrong, so any help would be greatly appreciated.
Thanks in advance.
Hi, 3 things:.
- Your image element ID is not ‘image1’ (change the code to fit you element ID).
- Your dataset ID is not ‘dynamicDataet’;
- Are you using gallery? repeater ? several static images? something else?