View Full Version : Cannot manipulate object in parent in Firefox

07-15-2005, 09:52 AM
I have placed an iFrame within a div and need to set the div's style="visiblity: hidden;" from within the iFrame when the user clicks the close button.

The following javascript works in IE.

parent.theDiv.style.visibility="hidden"; , how can I get it to work in Firefox??

07-15-2005, 10:27 AM
It depends upon what 'theDiv' is. If it is the id of the division then:

parent.document.getElementById('theDiv').style.visibility='hidden'should work.