TheVillageIdiot27
Programmer
I am having a problem with a DIV that sits in a list like this:
the javascript 'ajaxfunction' checks the class of list item above it then either writes a sub list to the div using an ajax function
if the class is closed (then updates the class to open), or if the class is open
However this is the bit that is letting me down. In Firefox it works fine but in IE, when the close action happens it leaves a small gap where the responseText use to be.
Is setting the innerHTML property of the div to '' different to setting it to null, which I assume is it's original state which displays fine?
Thanks in advance for any help recieved.
Code:
<ul>
<li id="folder1" class="closed">
<a href="javascript:ajaxfunction('1')">Item 1</a>
<div id="files1"></div>
</li>
<li id="folder2" class="open">
<a href="javascript:ajaxfunction('2')">Item 2</a>
<div id="files2"></div>
</li>
<li id="folder3" class="closed">
<a href="javascript:ajaxfunction('3')">Item 3</a>
<div id="files3"></div>
</li>
</ul>
the javascript 'ajaxfunction' checks the class of list item above it then either writes a sub list to the div using an ajax function
Code:
.innerHTML = xmlHttp.responseText;
Code:
.innerHTML = '';
Is setting the innerHTML property of the div to '' different to setting it to null, which I assume is it's original state which displays fine?
Thanks in advance for any help recieved.