Is it possible for a hyperlink to call TWO URLs?

C

Chris Ianson

Spartanicus said:
By the ignorant perhaps, for the rest of us it's a name attribute with
presumably a named link end for use with a link fragment identifier.

I use FrontPage, which calls them Bookmarks. E.g. 'Insert Bookmark'. Sorry
if I'm ignorant in your eyes. FrontPage has shifted a heck of a lot of
copies to other similarly ignorant people I guess. :S
 
C

Chris Ianson

It would really help if we could see an actual URL that demonstrates
this effect, so we don't just have to make blind guesses as to the
actual code you are using. A simple targetted hyperlink doesn't have
the "jumping" effect that you're citing, so perhaps you're doing some
silly thing like using an "onclick" JavaScript event on a hyperlink to
"#" alone, which indeed causes a pointless "jump" in the original page.
The best solution to this is not to do that; simply use the
destination URL in the "href" attribute and use a "target" attribute to
target the iframe. If for some reason it's actually necessary to have
an action take place in an "onclick" event without a real target URL in
the "href" attribute, you can end the JavaScript code with "return
false;" to suppress the jump, but you're still introducing
accessibility problems by not having your site work without Javascript.

I thought I'd explained it pretty well but I guess not! ;)

Here's an example page of what I'm trying to create:
http://tinyurl.com/rnqow

View it in a 1024x768 window and try clicking the Go To End and Go To Start
links. You will see it allows the users to navigate around the panorama,
however it also makes the entire browser window scroll down, presumably in
an attempt to line up the bookmark.. ahem! sorry, I mean "name attribute
with a named link end for use with a link fragment identifier".

I hope the working example helps you understand what is going wrong.
 
J

Jonathan N. Little

Chris said:
IE6 and IE7.


Problem #2.

Design with a browser that 'follows the rules first' then if needed your
can make adjustments for the one that doesn't.
 
C

Chris Ianson

Problem #2.

Design with a browser that 'follows the rules first' then if needed your
can make adjustments for the one that doesn't.

Try my link below in a browser you think follows the rules and let me know
if it does the exact same thing, meaning IE6, IE7 and FrontPage are not the
problems.

My understanding is the scrolling I am experiencing is 'by design'.
However, what I am asking is how to call 2 URLs from one hyperlink, nothing
more nothing less.

Thanks to anyone able to answer the Q :)
 
D

Dan

Chris said:
I use FrontPage, which calls them Bookmarks. E.g. 'Insert Bookmark'. Sorry
if I'm ignorant in your eyes. FrontPage has shifted a heck of a lot of
copies to other similarly ignorant people I guess. :S

M$ has a long history of unilaterally changing terminology to the
confusion of everybody who uses computer terms correctly. Some other
computer and online-service companies have joined in as well, leading
to there being a whole bunch of misuses popular with the drooling
newbies. This translation dictionary may help:

Newbieism Correct term
-------------------------------------
-----------------------------------------------------
Favorites Bookmarks
Bookmarks Named anchors / fragment identifiers
Folders Directories / Subdirectories
Screen name Userid / Username
Refresh button Reload button
..htm file .html file
Smart quotes Stupid use of nonstandard characters
 
J

Jonathan N. Little

Chris said:
Try my link below in a browser you think follows the rules and let me know
if it does the exact same thing, meaning IE6, IE7 and FrontPage are not the
problems.

Below what!? Or are you one of those Googlites that think this thread is
on big web page, if so, it is not and I do no know which one of your
message has 'the link'
My understanding is the scrolling I am experiencing is 'by design'.
However, what I am asking is how to call 2 URLs from one hyperlink, nothing
more nothing less.

Thanks to anyone able to answer the Q :)

Be interested in seeing what you are trying to accomplish. Have answered
numerous with respect to the original question 2 URLs with 1 link only
possible with JavaScript. Whether or not you methodology is sound that
is debatable. IE and Frontpage do not follow W3C standard so if you want
to at least start out with compliant markup neither is a good choice for
development. I stand by my statement.
 
J

Jonathan N. Little

Chris said:
Well, FP working wonders for you here...ugh.

Anyway since you insist on frames, iframe frame whatever, you do not
need an link to call URLs, just a target attribute.

<a name="start" target="I1">
<a name="end" target="I1">

adjustment will need to be made for correct vertical positioning within
the frame, a WYSIWYG editor will not be able to figure that one out for
you.
 
C

Chris Ianson

Anyway since you insist on frames, iframe frame whatever, you do not need
an link to call URLs, just a target attribute.

<a name="start" target="I1">
<a name="end" target="I1">

adjustment will need to be made for correct vertical positioning within
the frame,

But how does this let me jump from the left of the panorama to the right of
the panorama? "I1" is just the frame, not the name/bookmark position within
it.

In my link of you try clicking Go To End it jumps you to the far right of
the panorama, right?

Simply, how do I achieve this without scrolling down the entire web page?
Or, if the entire web page has to scroll down, how do I scroll it back up
again to compensate?

Thanks for your help!
 
J

Jonathan N. Little

Jonathan N. Little wrote:
Anyway since you insist on frames, iframe frame whatever, you do not
need an link to call URLs, just a target attribute.

Now in English:

Anyway since you insist on frames, (iframe frame whatever), you do not
need a link to call two URLs, all you need is a target attribute.
 
J

Jonathan N. Little

Chris said:
But how does this let me jump from the left of the panorama to the right of
the panorama? "I1" is just the frame, not the name/bookmark position within
it.

In my link of you try clicking Go To End it jumps you to the far right of
the panorama, right?

Simply, how do I achieve this without scrolling down the entire web page?
Or, if the entire web page has to scroll down, how do I scroll it back up
again to compensate?

Thanks for your help!

Just add 'target="I1"'to both links and then witness. If you are still
confused, then it will be a sign for "gettin' some ed-geew-mi-cation"
 
S

Spartanicus

Chris Ianson said:

That's actually a clever trick you're trying to pull there,
unfortunately it's to clever.

Afaik browser behaviour for what you are trying to do is undefined. It
sort of works in IE and FF, it does nothing in Opera. The fact that the
mother document is also repositioned in the viewport when one of the
links in the iframe is clicked is something you cannot fix.

The proper way to scroll the image in the iframe is by using the
scrollbar, point that out to users via a text prompt if you're worried
that they won't get it.
 
C

Chris Ianson

That's actually a clever trick you're trying to pull there,
unfortunately it's to clever.

Thanks. At last someone who gets it!
Afaik browser behaviour for what you are trying to do is undefined. It
sort of works in IE and FF, it does nothing in Opera. The fact that the

When you say "sort of works", is there a problem with it? It works fine for
me as far as jumping within the iframe goes.

Is there an online emulator for Opera and FF I can play with?
mother document is also repositioned in the viewport when one of the
links in the iframe is clicked is something you cannot fix.

Ahh, but if I could jump back up to another bookmark that is positioned
exactly where I wanted everything to line up, then although I couldn't "fix"
it, I could circumvent it.
The proper way to scroll the image in the iframe is by using the
scrollbar, point that out to users via a text prompt if you're worried
that they won't get it.

That I get, but as I didn't want to confuse people too much I didn't mention
what has now become relevant:

I have a second panorama image ('image2') which will be loadable into that
iframe by the user.
* E.g. they click a jump tag (book mark/name ref) on the sea on the left of
image1, and it will load image2 into that iframe, positioning image2 on the
left of the iframe, showing underwater on the left.
* Click the jump tag in the middle, you image2 but the scrollbar jumps to
the middle of image2.
* Click the jump tag on the right, you get the right-edge of image2 and the
iframe scrollbar positions itself automatically all the way to the right.

This allows the user to jump to anywhere in an image, so each click relates
to what they expect to see. That is why I don't want them to have to do the
scrolling, because every jump tag would just take them to the left of
image2. Not as fun.

I assume from all this that there is no way to call 2 jump tags from 1
hyperlink?
 
C

Chris Ianson

Jonathan N. Little said:
Just add 'target="I1"'to both links and then witness. If you are still
confused, then it will be a sign for "gettin' some ed-geew-mi-cation"

Sorry Jonathan but I don't think you understand what the problem is or what
I'm trying to do. I tried your suggestion even though I couldn't understand
what it would solve, and it did nothing different.

It still makes the whole page scroll down. If you refer to my other recent
post to Spartacus in this thread, you will see he has understood the issue.
Hopefully between all our brains we will be able to find a way around the
problem.
 

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,483
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top