Robert Bell
03-21-2003, 11:53 AM
Hi
I'm having a problem with an innerHTML command.
Using ASP and JavaScript I have a DIV tag like below
<DIV ID="HideDept" STYLE="Visibility: Hidden">
<TABLE>
<tr>
<td><img src="btsubtract.gif"></td>
<td><b>Trust</b></td>
</tr>
</TABLE>
</DIV>
And this DIV tag
<DIV ID="ShowDept" STYLE="Visibility: Visible"></DIV>
As you can see the ShowDept is empty and Visible to the user. HideDept isn't visible and should never be seen by the user. The JavaScript function is shown below.
ShowDept.innerHTML = HideDept.innerHTML;
The contents from HideDept are displayed in the ShowDept layer but there is a side effect. It looks like the visibility of the HideDept changes to visible because further down the page from the ShowDept DIV the HideDept DIV contents are repeated.
I have checked and there are no other DIV's called ShowDept.
Can anyone help?
I'm having a problem with an innerHTML command.
Using ASP and JavaScript I have a DIV tag like below
<DIV ID="HideDept" STYLE="Visibility: Hidden">
<TABLE>
<tr>
<td><img src="btsubtract.gif"></td>
<td><b>Trust</b></td>
</tr>
</TABLE>
</DIV>
And this DIV tag
<DIV ID="ShowDept" STYLE="Visibility: Visible"></DIV>
As you can see the ShowDept is empty and Visible to the user. HideDept isn't visible and should never be seen by the user. The JavaScript function is shown below.
ShowDept.innerHTML = HideDept.innerHTML;
The contents from HideDept are displayed in the ShowDept layer but there is a side effect. It looks like the visibility of the HideDept changes to visible because further down the page from the ShowDept DIV the HideDept DIV contents are repeated.
I have checked and there are no other DIV's called ShowDept.
Can anyone help?