View Full Version : creating DIVs with javascript, not displaying properly in IE

07-20-2007, 07:22 PM
The idea is to have a home-grown drill-down feature aside from the mootools stuff.

There is a div with a link. When that link is clicked, it opens a new div just beside the original div. The new div also has a link. When that one is clicked it opens a new div just beside that one, and so onů

Its working. To an extent. Looks wonderful in FireFox (and Safari). In IE 6 it works somewhat, but the CSS seems to be messed up and the styling of the DIV is not pulling through.

Curious of ways I can troubleshoot or if anyone else has encountered similar solutions.

Sample here:
thelast5.com/temp/csstest.html (http://thelast5.com/temp/csstest.html)

07-20-2007, 09:50 PM

newdiv.setAttribute('class', 'groupDiv');

newdiv.setAttribute('className', 'groupDiv');

It appears that IE doesn't recognize 'class' but knows 'className',
therefore it wasn't applying the correct CSS style.