If user want to change the CSS property of an HTML Objects on the fly, you can use JQuery,
For example, if you want to change the color of all the text in a <DIV> element,
HTML
For example, if you want to change the color of all the text in a <DIV> element,
HTML
<div id="change">Make Me in Red Color</div>
<button id="color">Change Color</button>
JQuery
$(document).ready( function() { $("#color").click( function() { $("#change").css("color", "red"); }); });
DEMO
No comments:
Post a Comment