SitePoint Sponsor

User Tag List

Results 1 to 8 of 8
  1. #1
    Non-Member Siltrince's Avatar
    Join Date
    Aug 2001
    Location
    Belgium
    Posts
    304
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Anchor link to top

    Hi people , I've got a little problem that's irritating me.
    I have (currently) 2 anchorlinks to the top of my webpage.

    After clicking the link it goes all the way to the top in IE6 but in Mozilla 1 and Opera 6 it doesn't go all the way to the top.
    If you watch the scrollbar you notice there are 3-4 pixels left at the top.

    I've put my anchor all the way at the top , just under my body tag but for some reason they don't want to go all the way up.


    note: I can imagine this being asked before , but I couldn't find any thread about it so , sorry if I'm the 1.000.000 person to ask.
    Last edited by Siltrince; Oct 17, 2002 at 10:25.

  2. #2
    Degrading Gracefully PalmerB's Avatar
    Join Date
    Sep 2001
    Location
    Ohio - U.S.A. Outlook: Cautiously Optimistic
    Posts
    3,283
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Hum, that's weird. Do you have a link to the page? That would help. Might be a doctype thing

    Palmer

  3. #3
    Non-Member Siltrince's Avatar
    Join Date
    Aug 2001
    Location
    Belgium
    Posts
    304
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Yep , here is the link: http://dev.hfc.be/siltrince/documents/

  4. #4
    Degrading Gracefully PalmerB's Avatar
    Join Date
    Sep 2001
    Location
    Ohio - U.S.A. Outlook: Cautiously Optimistic
    Posts
    3,283
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Thanks I'll take a look at it and get back to you.

    palmer

  5. #5
    Non-Member Siltrince's Avatar
    Join Date
    Aug 2001
    Location
    Belgium
    Posts
    304
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Thanks a lot

  6. #6
    Degrading Gracefully PalmerB's Avatar
    Join Date
    Sep 2001
    Location
    Ohio - U.S.A. Outlook: Cautiously Optimistic
    Posts
    3,283
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I believe it is a doctype thing Yours is stated as strict, this might cause problems with certain browsers.

    Change...
    <!DOCTYPE html
    PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

    with...
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">

    Let me know if that helped.

    Good luck,
    Palmer

  7. #7
    Non-Member Siltrince's Avatar
    Join Date
    Aug 2001
    Location
    Belgium
    Posts
    304
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Thanks PalmerB , I'll give a go and I'll let you know.

  8. #8
    Ribbit... Eric.Coleman's Avatar
    Join Date
    Jun 2001
    Location
    In your basement
    Posts
    1,268
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Don't use an anchor, use a link with the following as the HREF:

    javascript:scroll( 0, 0 );
    Eric Coleman
    We're consentratin' on fallin' apart
    We were contenders, now throwin' the fight
    I just wanna believe, I just wanna believe in us


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •