# Use Image as "Return To Top" button



## Linkmaster (Jul 25, 2006)

Here is what I want to do (if it is possible) (java script is ok)

Here is my site :
http://members.cox.net/mt4202/

The home made ND flag scrolls with you.

I would like to make that, when clicked on, a Return To Top button

Leaving it as is (scroll function and all)

Is this possible and what is the code ??

Thanks all !!


----------



## gamerman0203 (Oct 28, 2005)

since that flag is the background for the page, I'm not sure of any efficient way of doing this other than to put in the <body onClick="location.href='#top'"> and then put <a name="top"></a> at the very top of the page. But this will make it so when anyone clicks the page in any spot other than a link or object, they will be sent to the top. It won't be specificly for the flag image. This could get annoying because if someone is reading and they accidentally click somewhere, they will be sent to the top whether meant it or not.


----------



## Linkmaster (Jul 25, 2006)

Thanks


----------



## DJ-Zep (Mar 11, 2006)

You can add a "Back to the top" link at the end of ever section if you wanted...


----------

