javascript - Detecting an html attribute's value with a userscript? -
i trying make myself personal user script, need detect html attribute's value. example:
<div id="a">stuff</div> <div id="b" value="false"></div>
how create if statement in script, triggers if "value" attribute of element b turns true?
element = document.getelementbyid("b"); if(element != null) { if (element.value == "true") { // } }
Comments
Post a Comment