homepage Welcome to WebmasterWorld Guest from 54.237.71.86
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Become a Pro Member
Home / Forums Index / Code, Content, and Presentation / HTML
Forum Library, Charter, Moderators: incrediBILL

HTML Forum

    
Back to top marker
How can i make the marker 'back to top' work in Mozilla
Uzil




msg:3116903
 3:08 pm on Oct 11, 2006 (gmt 0)

Hello everybody
Does anybody know how to make the marker #top work for F.Fox and Mozilla.
I'm not actually looking for the marker for FF or Mozilla, I'm looking to find out a marker that works with every browser.

Unfortunatly <a href="#top">top</a> only works for IE.
Shouldn't this marker work for every browser?

 

coopster




msg:3116998
 4:10 pm on Oct 11, 2006 (gmt 0)

That should work just fine in FF/Moz, even with an empty <a> anchor [w3.org]. Do you have the anchor named at the "top" marker?

milanmk




msg:3117075
 4:57 pm on Oct 11, 2006 (gmt 0)

JavaScript Solution

<a href="javascript:window.scrollTo(0,0);">Back To Top</a>

Hope it helps.

Milan

Robin_reala




msg:3117393
 9:18 pm on Oct 11, 2006 (gmt 0)

I believe IE lets you specify a fragment of #top without an element with an id of ‘top’ and it'll still work. This is rather weird, but hey.

The obvious fix is to give the first element in your page an id of ‘top’

bluesmandeluxe




msg:3122964
 4:28 pm on Oct 16, 2006 (gmt 0)

Like Coopster saud, so long as you have the named anchor in position at the top <a name="top"></a>, then <a href="#top">top</a> anywhere in the document will work in any browser.

Global Options:
 top home search open messages active posts  
 

Home / Forums Index / Code, Content, and Presentation / HTML
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved