I know some css, but easily get in trouble with js. Jscher provided a bookmarklet to fix a recent Google Maps glitch that disables its Labels checkbox:
Code: Select all
javascript:var btn=document.querySelector('button[jsaction=%22layerswitcher.intent.labels%22]');btn.removeAttribute('disabled');btn.click();void 0;
Now I'm trying to adapt a variant of this to stop a carousel image display on a website. I've learned that I have to add a new attribute
data-bs-interval="false" to the div containing the carousel, and it works manually editing the HTML, but this code is not doing that:
Code: Select all
javascript:var csl=document.querySelector('div[id=%22carousel-img%22]');csl.addAttribute('data-bs-interval','false');void 0;
Adding quotes (%22) around "false" doesn't help. I'm probably just not using addAttribute correctly?