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 Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

LINKS WILL NOT OPEN IN THE SPECIFIED 'TARGET FRAME'

Status
Not open for further replies.

ARRRRRRRRRR

Technical User
Nov 24, 2007
4
GB
Hi,

I have produced a website with multiple frames. The top one contains a navgation bar, where the links should open up in the frame below. I have specified the target frame for the links as that frame (called contentframe), but they still open up as a new window, leaving the original window unaltered. The nearest thing i can get to this working how i want it to is by setting the target frame to '_self', which opens up the link in the frame containg the navbar (which is not good!). Have i missed something - i have had working navbars of a similar spec in other websites that have worked fine, so im not sure whats happened)

Any suggestions??
 
Much as I despise frames, this should be relatively easy to do.
Code:
<html>

<frameset cols="120,*">

<frame src="nav.htm">
<frame src="content.htm" [b]name="contentframe"[/b]>

</frameset>
</html>
You must have the name defined.
Code:
<html>
<body>
<a href ="content.htm" [b]target ="contentframe"[/b]>Frame a</a><br>
<a href ="content_b.htm" [b]target ="contentframe"[/b]>Frame b</a><br>
<a href ="content_c.htm" [b]target ="contentframe"[/b]>Frame c</a>
</body>
</html>
This working example adapted from the w3schools Web site.

Greg
"Personally, I am always ready to learn, although I do not always like being taught." - Winston Churchill
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top