[thelist] Scrolling heirmenus and internal links

Robert Goodyear rob_goodyear at yahoo.com
Fri Oct 26 11:12:25 CDT 2001


Why don't you use a 1-pixel 'rail' down the right side of the page that contains nothing
but anchors followed by 120-pixel spacer gifs, all VALIGN=bottom'ed to the cell above the
target that follow along beside your page content?

--- George Dillon  -  WoW Evolt! <evolt at georgedillon.com> wrote:
> I'm in the process of adding a dynamic hierarchical menu to my site and want
> the masthead (of which it is a part) to be always visible at the top of the
> browser window (done using a looping function).
> 
> Its working but it now my internal links (e.g. <a href="#targetonthispage">)
> are a problem, since when the '#' link is clicked, the document jumps to
> the anchor (as normal) and then the masthead drops into place and obscures
> the
> top of the page (where the anchor is).
> 
> I *could* solve the problem by adding an onclick function to all my # links,
> thusly:
> 
>   function scrollHash() { hashUp=setTimeout("scrollBy(0,-120)",200)}
> 
>   <a href="#targetonthispage" onclick="scrollHash()">
> 
> but obviously I'd rather not have to change numerous existing links and then
> have to remember to add this code into all new internal links (and besides
> this will only work on the page and not if the page is opened with a hash in
> the URL).
> 
> Is there a simpler solution?
> 
> TIA
> 
> George Dillon
> 
> 

__________________________________________________
Do You Yahoo!?
Make a great connection at Yahoo! Personals.
http://personals.yahoo.com




More information about the thelist mailing list