Wayne88
asked on
How to control element on another Iframe from an Iframe (see description)
hi there,
if i have a page with two iFrames (1 and 2). how can i control the elements in iFrame2 from iFrame1. for example, if I like to hide a button on iFrame2 when a button in iFrame1 is clicked.
please provide syntax.
thanks in advance
if i have a page with two iFrames (1 and 2). how can i control the elements in iFrame2 from iFrame1. for example, if I like to hide a button on iFrame2 when a button in iFrame1 is clicked.
please provide syntax.
thanks in advance
ASKER
hi jonahzona, thanks for your help but i cannot seems to get the syntax right. i had tried almost everything:
//document.getElementById( 'I2').setA ttribute(' src','www.google.ca');
//val = "document.all("www.google.ca").value;";
//document.all.I2.src=val;
//var myFrame = document.getElementById('I 2');
//myFrame.src = "http://www.yahoo.com";
//window.frames.I2.locatio n="http://www.yahoo.com";
//document.write("http://server/cgi-bin/calendar.pl?target=calendarContainer&...'><\/scri pt>");
where I2 is the name of my second frame and i am trying to send a link from frame I1
//document.getElementById(
//val = "document.all("www.google.ca").value;";
//document.all.I2.src=val;
//var myFrame = document.getElementById('I
//myFrame.src = "http://www.yahoo.com";
//window.frames.I2.locatio
//document.write("http://server/cgi-bin/calendar.pl?target=calendarContainer&...'><\/scri
where I2 is the name of my second frame and i am trying to send a link from frame I1
When I get home tonight, if this is still unanswered I'll help you out.
Going to a rehearsal dinner for my brothers wedding, so I will be unavailable for a few hours...
Going to a rehearsal dinner for my brothers wedding, so I will be unavailable for a few hours...
ASKER
thanks, no hurry. enjoy.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Solved my problem by using regular frame instead of iFrame.
http://www.dyn-web.com/tutorials/iframes/refs.php
Syntax provided on page.