> I have a page with two frames. I want to put a "remove
> frames" link on one so the user can have a bit more
< screen real estate if they want to. This is no problem.
> I just create a link to itself with a target="top" attribute.
> But, once it's out of frames, how can I detect this
> and not have the "remove frames" link appear on the page?
Replace your link with this:
<SCRIPT LANGUAGE="JavaScript">
if (top.location.href != location.href) {
document.write('<A HREF="mypage.cfm" TARGET="_top">Remove Frames</A>');
}
</SCRIPT>
Dave Watts, CTO, Fig Leaf Software
http://www.figleaf.com/
voice: (202) 797-5496
fax: (202) 797-5444
------------------------------------------------------------------------------
Archives: http://www.eGroups.com/list/cf-talk
To Unsubscribe visit
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk or send a
message to [EMAIL PROTECTED] with 'unsubscribe' in the body.