View Full Version : Can All Levels Navigational Menu always drop DOWN?

01-26-2010, 05:59 PM
1) Script Title: All Levels Navigational Menu

2) Script URL (on DD): http://www.dynamicdrive.com/dynamicindex1/ddlevelsmenu/index.htm

3) Describe problem: I'm using the topbar version with dropdowns of some considerable length. Of course, in some instances the browser window size causes a sub to appear upward. My client wants all these subs to drop down - not up. Is there a way to alter the script to force the subs always to appear below the topbar and not above?

Thanks as always.:)

01-26-2010, 11:16 PM
Try finding the below block of code inside the .js file, and commenting it out (new part in red):

if (submenubottomedge-scrollY>ddlevelsmenu.docheight){ //no room downwards?
if (this._dimensions.submenuh<this._offsets.top+(dir=="sidebar"? this._dimensions.h : 0)-scrollY){ //move up?
menutop+= - this._dimensions.submenuh + (this._istoplevel && dir=="topbar"? -this._dimensions.h : this._dimensions.h)
else{ //top of window edge
menutop+= -(this._offsets.top-scrollY) + (this._istoplevel && dir=="topbar"? -this._dimensions.h : 0)

01-27-2010, 06:04 AM
Thank you ! that worked.
I knew there was way - but not being well-versed in js, I didn't want to mess things up.