pinkstonm
asked on
Page with iframe ?
I have a page with an iframe in it and the outer part of the page has a button that I want to when clicked modify the contents of the iframe.
The iframe statement I have is
<!-- <p class="headlines" style="margin-bottom: 2px"> -->
<iframe src="inc_sitelist.asp" width="100%" height="100%" frameborder="1" name="news" style="padding-right: 0px" marginheight="5" marginwidth="5"> </iframe>
<!-- </p> -->
The the button is clicked I would like the contents to change to inc_adminlist.asp.
Any thoughts?
Thanks
The iframe statement I have is
<!-- <p class="headlines" style="margin-bottom: 2px"> -->
<iframe src="inc_sitelist.asp" width="100%" height="100%" frameborder="1" name="news" style="padding-right: 0px" marginheight="5" marginwidth="5"> </iframe>
<!-- </p> -->
The the button is clicked I would like the contents to change to inc_adminlist.asp.
Any thoughts?
Thanks
ASKER
<a href=_blank class="grey" onclick="document.getEleme ntById('ne wsid').src ='inc_admi nlist.asp' ;" onmouseover="return overlib('Site List Master administrative functions including security', BGCOLOR, '878787', FGCOLOR, 'E6E6E6', CAPCOLOR, 'FFFFFF', CAPTION, 'administrative functions');" onmouseout="return nd();">admin</a>
I tried to put in a _blank but that does not work if I remove the href it works but distorts the look of the value becuase of css values.
Anythoughts
I tried to put in a _blank but that does not work if I remove the href it works but distorts the look of the value becuase of css values.
Anythoughts
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
If the button is in the main part of the page and you want to change the iframe contents, all you need is to add a target to a regular link. iFrames work just like regular frames.
ASKER
Thanks works nice
<iframe src="http://www.google.com" width="100%" height="100%" frameborder="1" id="newsid" name="news" style="padding-right: 0px" marginheight="5" marginwidth="5"> </iframe>
<input type="button" name="btn" value="Click" onclick="document.getEleme