I'm simply trying to remove an iframe
from the DOM using a chrome extension I'm building.
This code isn't removing the iframe
.
var frame = document.getElementById( "tracking" );
frame.parentNode.removeChild( frame );
My manifest file is set up correctly. I'm able to access other elements on the page like this:
var bg = document.getElementById( "someId" );
bg.parentNode.removeChild( bg );
Why can't I remove the iframe
?