SitePoint Sponsor |
|
User Tag List
Results 1 to 5 of 5
Thread: Static Drop Down Menu
-
Nov 15, 2001, 19:03 #1
- Join Date
- Nov 2000
- Posts
- 224
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Static Drop Down Menu
Hi,
I've been playing around with HierMenu (http://www.webreference.com/dhtml/) and as I couldn't use it on a different frame I thought I would try and use some other script to make it static....But hey! I've not been able to and need some help if possible?
Has anyone used HierMenu? and if so do you know if there is a way to keep it static on the page as you scroll down?
Thank you!
-
Nov 15, 2001, 21:55 #2
Just go to http://www.dynamicdrive.com and pick a navigation system from there.
-
Nov 16, 2001, 04:48 #3
- Join Date
- Nov 2000
- Posts
- 224
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Drop Down Menu
Thanks but none of the ones there will fit into my design.
I know what I need to do and that is to learn how to write my own javascripts, but hey! I don't have a lot of time so all I can do at the moment is try and get help from others and customise scripts that I download.
If any one can 'help' thank you.
-
Nov 17, 2001, 11:25 #4
- Join Date
- Feb 2000
- Location
- where the World once stood
- Posts
- 700
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Hi Tezdread,
I am not familiar with Heirmenu. However, if you want to make it static, the script below might work. It should be called from the onLoad event handler -- onLoad="init('nameOfDiv')". Simply replace 'nameOfDiv' with the name of your menu's main div.
Vinny
<script language="javascript">
<!--
var oldY=0;
function scrollDiv(divID)
{
var yPos = (document.all || document.getElementById) ? document.body.scrollTop : window.pageYOffset;
var divStyle = (document.getElementById) ? document.getElementById(divID).style : ( (document.all) ? document.all[divID].style : document.layers[divID] );
if (yPos != oldY)
{
divStyle.top = yPos;
oldY = yPos;
}
}
function init(divID)
{
scrollDiv(divID);
setTimeout("init('"+ divID + "')", 60);
}
</script>Where the World Once Stood
the blades of grass
cut me still
-
Nov 20, 2001, 17:11 #5
- Join Date
- Nov 2000
- Posts
- 224
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Menu
Hi Vinny and thank you for your help, unfortunately the script would not work. The problem with the HierMenu is there are two .js files one being a loader and also the location of the menu has to be specified within the .js file.
I tried using layers also but none of this would work. The only thing I could do was to use an anchor point before the script so that I could have links down the page to take me directly to the menu.
Thanks again
Tezdread
Bookmarks