order of iframe loading with document loading

O

ofir

I have a page with iframe that i can only reach to it's attached .js
file.
i'm trying to change the src of the iframe but the only this i found
is:
document.attachEvent("onreadystatechange",startup)
function startup()
{
try{
var iframes = document.getElementsByTagName("IFRAME");
iframes(0).src = "http://www.blablabla.com";
catch(e){}
}

it worked but only after it allready loads the content of the iframe
so it first loads the original src and then my new one.
can I attach to an event that run before the original src loads into
the iframe?

thanks,
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,483
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top