Q:

Any event to detect when the "Class" attribute is changed for a control

I have a "div" control with some id="myDiv" class="myClass"
var var1=10;
in Javascript. Based on user  action I will change the class for this control from "myClass" to "newClass" so when this has happened I want to change the value of var1 to 20.
So how would I recognize that change in Class?

A:

You may use onpropertychange(IE) and DOMAttrModified (others)

