Named anchor question

Discussion in 'HTML' started by Mark Parnell, Jun 28, 2005.

  1. Mark Parnell

    Mark Parnell Guest

    Mark Parnell, Jun 28, 2005
    #1
    1. Advertising

  2. Mark Parnell

    LaBlueGirl Guest

    Newbie here.
    Working on an exercise document.
    Question:
    The first named anchor was included in the heading. The link to it was
    in the following paragraph. Link worked fine.
    The second named anchor has no heading to fit neatly into. I can't
    figure out where to place it to make the link work.
    Here's a bit of the source code I was working on:
    <h1 size="2" name="top">Inline Anchors</h1>
    <p>I would like to click <a href="#middle">here</a> and be at the
    middle of the page.</p>
    <hr width="65%" align="center">

    <p><b>Middle!</b> But I would like to click <a href="#top">here</a> and
    be back to the top of the page<br />
    or click <a href="#bottom">here</a> and be thrown to the bottom of the
    page.</p>
    <hr width="65%" align="center">

    Where do I put the named anchor in the second paragraph? I have tried
    just about everywhere and I can't get the first link of the second
    paragraph to work....

    Thanks
    LBG

    --
    Yo momma is so fat she eats Wheat Thicks.
    Yo momma so stupid she got stabbed in a shoot out.
    Yo momma so ugly even Rice Krispies won't talk to her.
    Yo momma so fat when she went outside, everyone yelled, "Hey,
    Kool-Aid!"
    Yo momma so stupid she took the Pepsi challenge and chose Jif.
    Yo momma is so nasty she has to creep up on the bathwater.
    Yo momma so hairy it looks like she got Buckwheat in a headlock.
    LaBlueGirl, Jun 28, 2005
    #2
    1. Advertising

  3. LaBlueGirl wrote:

    > Newbie here.
    > Working on an exercise document.
    > Question:
    > The first named anchor was included in the heading. The link to it was
    > in the following paragraph. Link worked fine.
    > The second named anchor has no heading to fit neatly into. I can't
    > figure out where to place it to make the link work.
    > Here's a bit of the source code I was working on:
    > <h1 size="2" name="top">Inline Anchors</h1>
    > <p>I would like to click <a href="#middle">here</a> and be at the middle
    > of the page.</p>
    > <hr width="65%" align="center">
    >
    > <p><b>Middle!</b> But I would like to click <a href="#top">here</a> and
    > be back to the top of the page<br />
    > or click <a href="#bottom">here</a> and be thrown to the bottom of the
    > page.</p>
    > <hr width="65%" align="center">
    >
    > Where do I put the named anchor in the second paragraph? I have tried
    > just about everywhere and I can't get the first link of the second
    > paragraph to work....
    >
    > Thanks
    > LBG
    >

    Anchor:

    <a name="anchorMe"></a>
    ..
    ..
    ..
    ..
    <a href="#anchorMe">Jump to anchorMe!</a>

    --
    Take care,

    Jonathan
    -------------------
    LITTLE WORKS STUDIO
    http://www.LittleWorksStudio.com
    Jonathan N. Little, Jun 28, 2005
    #3
  4. Mark Parnell

    Ian Rastall Guest

    On Mon, 27 Jun 2005 19:15:54 -0700, "LaBlueGirl" <>
    wrote:

    >Where do I put the named anchor in the second paragraph? I have tried
    >just about everywhere and I can't get the first link of the second
    >paragraph to work....


    Hi LBG. One thing to keep in mind is that if the page is all on the
    screen, you won't see it move.

    As far as where to put the anchor, it can go outside the block-level
    element, though it's not supposed to. You could always put it in a
    <div>, like:

    <div><a id="middle" name="middle"></a></div>

    which might even validate!

    HTH

    Ian
    --
    Was it not a comedy, a strange and stupid
    matter, this repetition, this running around
    in a fateful circle? (Hermann Hesse)
    http://www.bookstacks.org/
    Ian Rastall, Jun 28, 2005
    #4
    1. Advertising

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

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Nalaka

    named anchor

    Nalaka, Dec 23, 2005, in forum: ASP .Net
    Replies:
    6
    Views:
    542
    Steven Cheng[MSFT]
    Dec 29, 2005
  2. Replies:
    1
    Views:
    512
  3. Greg Collins [Microsoft MVP]

    Get the named anchor from the URL?

    Greg Collins [Microsoft MVP], Oct 11, 2006, in forum: ASP .Net
    Replies:
    6
    Views:
    604
    Greg Collins [Microsoft MVP]
    Oct 12, 2006
  4. Robert Mark Bram

    Jump to named anchor after form processing

    Robert Mark Bram, Oct 20, 2004, in forum: ASP General
    Replies:
    3
    Views:
    183
    Evertjan.
    Oct 21, 2004
  5. John
    Replies:
    1
    Views:
    83
    Lasse Reichstein Nielsen
    Aug 2, 2003
Loading...

Share This Page