Help with links inside frames.

P

Pen Phill

Hi I hope someone can help if possible.

I am currently playing with html and the frameset function. I have a site that
contains some very wide angle images that require to scroll L and R. With a
simple page the text underneath the images is only a screen wide and so also
scrolls and disappears. I thought frames might be an answer so I have set up a
frameset page that produces a page with two frames "top" and "bottom". At the
outset these contain respectively the image (image1.htm) and a block of text
(text1.htm). On opening up this page (framepage.htm) in IE the image in the top
frame can be scrolled separately to the block of text in the bottom frame which
is what I want. The problem I have is changing to the next or previous image
AND the next or previous text block by clicking on a link that appears in the
lower of the two frames. That is I want to change the contents of BOTH frames
by clicking on a link which is present in the lower one. Can it be done?

The text blocks for each image currently have the "previous/next" links in
the form:...."PREVIOUS.....Text block.......NEXT
The current code for the page in the lower frame "bottom" which is text1.htm
is as follows:

<html>
<head>
<meta http-equiv="Content-Type"
<Content = text/html:charset = iso-8859-1">
<meta name=generator" content="Microsoft front Page Express 2.0">
<title="text1"</title>
<base target ="top">
</head>
<body bgcolor="#FFFFFF">
<p> PREVIOUS This is the block of text <a href="image2.htm">NEXT</a></p>
</body>
</html>

This code just changes the image from image 1 to image2 in the top frame when
NEXT is clicked.That's only half of what I want. How can I alter this code so
that NEXT also puts text2.htm with ITS links into the BOTTOM frame?
(and of course clicking PREVIOUS also gives image0.htm and text0.htm in the
respective frames?)
I have tried adding a base target = "bottom" line with a second a href
="text2.htm" but this doesn't work.

Phil

Can anybody help please?

Phil
 
S

Steve Pugh

I am currently playing with html and the frameset function. I have a site that
contains some very wide angle images that require to scroll L and R. With a
simple page the text underneath the images is only a screen wide and so also
scrolls and disappears.

And why is this a problem? The user reads the text before or after
looking at the full width of the imge. Their eyes can't be looking at
two things at once. If they want to see the text again they can scroll
back to it.
I thought frames might be an answer so I have set up a
frameset page that produces a page with two frames "top" and "bottom". At the
outset these contain respectively the image (image1.htm) and a block of text
(text1.htm). On opening up this page (framepage.htm) in IE the image in the top
frame can be scrolled separately to the block of text in the bottom frame which
is what I want. The problem I have is changing to the next or previous image
AND the next or previous text block by clicking on a link that appears in the
lower of the two frames. That is I want to change the contents of BOTH frames
by clicking on a link which is present in the lower one. Can it be done?

You need to set up a new frameset document for every pair of
image/text pages. Then link to the frameset with target="_top" to
fully replace the current frameset.

Steve
 
A

Andrew Davidson

Pen Phill said:
I am currently playing with html

Good. Use a good text editor, and watch this NG.
and the frameset function.

Bad. Ditch the frames. They are a dark alley that you don't want to walk down.
I have a site that
contains some very wide angle images that require to scroll L and R. With a
simple page the text underneath the images is only a screen wide

"a screen wide" is meaningless on the web. Your screen is not my screen. You can
never know how wide a screen is.
I thought frames might be an answer

You were wrong. Frames are only the answer if the question is "What is a bad way
to do this?".
 
P

Pen Phill

Hi All

Thanks for the replies.It obviously seems the idea of using frames is generally
considered a no no! I'll still have a play with them nevertheless but probably
stick to a simpler setup in the end Thanks..

Phil
 
P

Pen Phill

Subject: Re: Help with links inside frames.
From: brucie (e-mail address removed)
Date: 31/07/03 13:10 Romance Daylight Time
Message-id: <[email protected]>



as an academic exercise that if fine but don't use them for an actual
site.

http://html-faq.com/htmlframes/?framesareevil
http://homepage.ntlworld.com/l_vajzovic/tom/web/frames.html
http://www.karlcore.com/articles/article.php?id=2
http://david.us-lot.org/www/frames/

Thanks for these links. I shall have a browse.
Phil
 
P

Pen Phill

Subject: Re: Help with links inside frames.
From: Steve Pugh (e-mail address removed)
Date: 31/07/03 13:27 Romance Daylight Time
Message-id: <[email protected]>



You need to set up a new frameset document for every pair of
image/text pages. Then link to the frameset with target="_top" to
fully replace the current frameset.

Steve

If I understand this right (and I might not have :)), won't this just place
the complete new frameset in the old top frame, leaving the original text1 in
the lower frame and giving a set within a set within a set effect? I did try
setting the link in text1.htm to "framepage2.htm" hoping it would load the
complete new frameset in a new screen. Instead I got the Russian Doll effect!
I shall continue to play around with it however and hopefully learn but in
general advice here has been to give frames a miss. Thanks anyway.

Phil
 
P

Pen Phill

In short my question was how to have a single link inside the lower of two
frames that would either renew the contents of BOTH or renew the screen with a
new frameset.
Steve Pugh (e-mail address removed) replied in message:

Phil replied:
If I understand this right (and I might not have :)), won't this just place
the complete new frameset in the old top frame, leaving the original text1 in
the lower frame and giving a set within a set within a set effect? I did try
setting the link in text1.htm to "framepage2.htm" hoping it would load the
complete new frameset in a new screen. Instead I got the Russian Doll effect!

Phil
Phil further replied:
Thanks for the idea but I have just tried this both with and without the
command "target=" set .Using "target=" I can link the new item (image.htm or
text.htm) into either of the frames and using a straight link the chosen item
goes into the lower frame as expected.(where the link is.) Is there a way of
loading both frames with a single link?

If I link it to a new frameset.htm however, as you suggest, hoping to renew the
complete screen and have both frames renew with different contents, (like it
does if I click it straight from the older -not exactly what I want as it takes
longer,) it still comes up in the lower frame (or the target frame) but as
THE page with the two frames. Interestingly if I click the link in the lower of
these two frames it loads a further two frames in the new lower frame.....Its
the Fractal Sorcerers' Apprentice effect! It won't clear the screen and load
the new frameset in in a new window. In fact can what i want be done and if so
does anyone know how please?
Phil
 
E

Els

Phil replied:
Phil further replied:
Thanks for the idea but I have just tried this both with and without the
command "target=" set .Using "target=" I can link the new item (image.htm or
text.htm) into either of the frames and using a straight link the chosen item
goes into the lower frame as expected.(where the link is.) Is there a way of
loading both frames with a single link?

If I link it to a new frameset.htm however, as you suggest, hoping to renew the
complete screen and have both frames renew with different contents, (like it
does if I click it straight from the older -not exactly what I want as it takes
longer,) it still comes up in the lower frame (or the target frame) but as
THE page with the two frames. Interestingly if I click the link in the lower of
these two frames it loads a further two frames in the new lower frame.....Its
the Fractal Sorcerers' Apprentice effect! It won't clear the screen and load
the new frameset in in a new window. In fact can what i want be done and if so
does anyone know how please?
Phil

In short my question was how to have a single link inside the lower of two
frames that would either renew the contents of BOTH or renew the screen with a
new frameset.

I just read all this quickly, so forgive me if i missed anything, but
it seems that you are not using

target="_top",
but
target="top"

which isn't the same. "_top" is indicating the frame the current
frameset is in. As in parent, I think it's called.

Hope his helps,
Sincerely,

Els
 
J

JT

"Pen Phill" wrote in
Thanks for the replies.It obviously seems the idea of using frames is generally
considered a no no! I'll still have a play with them nevertheless but probably
stick to a simpler setup in the end Thanks..


No Phill, frames and tables are only generally considered a no, no by most
of the regular and extremely helpful people who post answers here. They are
quite happy to keep scrolling up and down pages for menus, where really for
most non technical surfers a static menu in a frame is much more sensible.
But then most surfers are not disabling all and sundry settings from their
browsers, which on the whole they will be using MS Explorer.

JT
 
A

Adrienne

"Pen Phill" wrote in



No Phill, frames and tables are only generally considered a no, no by
most of the regular and extremely helpful people who post answers here.
They are quite happy to keep scrolling up and down pages for menus,
where really for most non technical surfers a static menu in a frame is
much more sensible. But then most surfers are not disabling all and
sundry settings from their browsers, which on the whole they will be
using MS Explorer.

JT

Search engines does not use Internet Explorer. If a visitor arrives on an
orphan page listed by a search engine, and the static menu page is missing,
how is that non technical surfer supposed to navigate?
 
S

Steve Pugh

However I still have the problem that I cannot (or don't know how to) load a
NEW frameset in a NEW screen from a link in an existing frameset.

You've been told several times.
<a href="new.html" target="_top">
will replace all the existing frames with new.html. If new.html is a
frameset then you'll replace all the existing frames with that new
frameset.

Not the underscore, it's important.
or (what I
realy want to do) reset the two frames with new html content with a SINGLE
link from within one of the frames.

Only possible by replacing the entire frameset. See above and previous
messages.
ie have two targets and two hrefs in the html code for the lower frame.

That's impossible unless you use JavaScript, but then you have to
decide which of the two you want to work when JS is disabled.

Steve
 
A

Andrew Davidson

Adrienne said:
for most non technical surfers a static menu in a frame is
much more sensible.

Presumably these "non-technical" people are quite to happy deal with fact that
every bookmark from a framed site leads straight back to the home page?
 
E

Els

Pen Phill said:
OK I feel much happier now :))
However I still have the problem that I cannot (or don't know how to) load a
NEW frameset in a NEW screen from a link in an existing frameset. or (what I
realy want to do) reset the two frames with new html content with a SINGLE
link from within one of the frames.

ie have two targets and two hrefs in the html code for the lower
frame.

In addition to what Steve already said, here's an example.
Is this what you mean?
http://www.mediatech.nl/~rachel/temp-test/penphill/frameset3.html

Sincerely,
Els
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,744
Messages
2,569,484
Members
44,904
Latest member
HealthyVisionsCBDPrice

Latest Threads

Top