NameSilo

JavaScript and Grease Monkey - Replacing HTML Content

Namecheap AuctionsNamecheap Auctions
Namecheap AuctionsNamecheap Auctions
SpaceshipSpaceship
Watch

Schultz

New Member
Impact
0
I am looking to replace a iframe inside a html page with grease monkey in firefox.
Code:
// @include        *domain.com*
// ==/UserScript==
var theIframe = parent.frames[0].window.document.getElementsByTagName("IFRAME").item(0);
if (theIframe) {
     theIframe.style.display = "none";
}

That is the code I have so far but instead of removing the iframe I would like to replace it with a link to what was inside the iframe, could anyone point me in the right direction? I know very little JavaScript.
 
0
•••
The views expressed on this page by users and staff are their own, not those of NamePros.
GoDaddyGoDaddy
Did you mean hide the iframe or modify the iframe "content"?
 
0
•••
Dynadot — .com TransferDynadot — .com Transfer
CatchedCatched

We're social

Escrow.com
Spaceship
CryptoExchange.com
Domain Recover
DomDB
NameFit
  • The sidebar remains visible by scrolling at a speed relative to the page’s height.
Back