Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Force Link in Frame to use full browser window 2

Status
Not open for further replies.

zefir

Technical User
Sep 21, 2000
344
EU
In a frame is a link. The linked URL content should
be shown in the full browser window, not in the frame
window.
I apologize, if this has been asked here often.
Usually a direct question is very effective....
Gernot
 
you need to use javascript:

Code:
<script language=&quot;javascript&quot;>

function break() {

top.location.href = self.location.href 
//this will break your frames

window.location=&quot;newpage.htm&quot;
}

then your link is <a href=&quot;#&quot; onClick=&quot;break()>go to new page</a>
-Greg :-Q
 
Mackey: thank you very much for this prompt reply
and help. ---Gernot
 
Sorry, Greg: doesn´ t work.
A type error ?
&quot;break()&quot; doesn´t work either.
I am not familiar with Java, use just a few modules.
&quot;newpage.htm&quot; is certainly the complete absolute URL.
Any further help ? ----Gernot
 
goes in the <head>..I forgot the </script>, just use the link as you would with a regular one...

Code:
<script language=&quot;javascript&quot;>

function break() {

top.location.href = self.location.href 
//this will break your frames

window.location=&quot;newpage.htm&quot;
}
</script>
-Greg :-Q
 
If you put this, <BASE target=&quot;_top&quot;> inbetween your <HEAD> and </HEAD> tags then any normal HREF link will replace the frameset. Klae

You're only as good as your last answer!
 
yea but I think he needs to have it break frames on only 1 of the links though..right? -Greg :-Q
 
whether you use javascript or HTML it doesn't really matter but I like to not use javascript or stylesheets if I don't have to so I am only posting these replies to give zefir a choice of what method to use. Both are equally good.

If you want only one link to fulfill the entire window and replace the frameset then the link can look like this..

<A HREF=&quot;entireWindowPage.htm&quot;
TARGET=&quot;_top&quot;>go to page that fulfills the entire window, replacing the frameset</A>

Hope this helps..
Klae

You're only as good as your last answer!
 
Thanks to everybody - check it tomorrow.
---Gernot
 
Klae: I have tested <base target=&quot;_top&quot;>
This works fine - URL in the full window,
but E-Mail in the local window.
Probably this will be valid for all URLs.
Exactly what I was looking for.
Thank you very much.
Greg: I had added </script> anyway, but
it didn´t work. Nevertheless - thanks.
Indeed I prefer solutions with pure HTML.
---Gernot
 
Thanks, this solution has been already mentioned
by Klae. --Gernot
 
hmm...that should have worked...oh well...you got it solved...good luck with your site.. -Greg :-Q
 
what am I looking for?, if you type this in whatever language your page is in (german?) and then it gets changed to english tell what links you want me to click..just put -'s in between letters so it doesn't get changed.. -Greg :-Q
 
Greg: the issue &quot;Force Link in Frame to use full browser window&quot;
can be tested by &quot;Links&quot; and click on any link. It´s an organization
test, the content is not important.
Just to finish this thread successfully ....Gernot
 
Zefir,

nevertheless, a very tasteful site. Some might argue that it doesn't contain enough flashy, moving bits and pieces, but i like the calm, sober, linear looks a lot.

Regards,
Ronald.
 
Thanks, Ronald.
At present I stabilize the structure.
It´s well known, that JPEGs shouldn´t be rescaled,
because browsers don´t apply interpolation. BUT:
The true size should be used for width and height.
This means &quot;rescale to the original size&quot;. WHY ?
On a page with 9 images (here &quot;Personal=staff&quot;) the
browser will start immediately to show the first
images, because he knows the scale. Otherwise
the receiver has to wait until all images are loaded.
...Just &quot;discovered&quot; this and modified the code.
---Gernot
 
um...that page is still in your frames...I thought you were trying to break out of them? -Greg :-Q
 
Greg: &quot;that&quot; page is in the local frame, but
external links are in the large window - at least
here, using Explorer or Netscape.
Please tell me if you find errors. ----Gernot.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top