What happens on IE, our favorite browser, when you try to setup a class attribute on a DOM element? Actually this is not possible, because setAttribute(‘class’, ‘my-class’) is obviously working only on non-IE browsers.
On IE actually you should setup the class on an element with that structure:
element.setAttribute('className', 'my-class');
Related posts:
- CSS Priority: The Difference Between a.my-class and .my-class
- cssText and how it can be very very useful
- Friday Algorithms: A Data Structure: JavaScript Stack




Сайт отличный. Надо бы Вам награду вручить за него или просто почетный орден. =)