106
rated 0 times
[
112]
[
6]
/ answers: 1 / hits: 17569
/ 12 Years ago, thu, may 3, 2012, 12:00:00
I am using this JavaScript code to remove a couple elements from the page, but it's not working. When I inspect the code with Opera Dragonfly it says something like:
Uncaught exception: Error: WRONG_ARGUMENTS_ERR
and points to the file and function name.
The weird thing is that I use the exact same code in another function on the same page and it works without problem. The code is very small and simple:
var docBody = document.getElementById(body);
if(document.getElementById(marginDiv)){
docBody.removeChild(marginDiv);
}
Both body
and marginDiv
exist on the page. My goal is to make the thumbnails disappear when one clicks the background.
More From » removechild