PDA

View Full Version : Chrome CSS Drop Down Menu Question



Jon101
11-23-2007, 07:58 PM
1) Script Title: Chrome CSS Drop Down Menu (v2.01)

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

Is there any way to make the drop down centered under the link from where it drops, rather than having it slide down aligned towards the right?

Thanks!!

Jon


Please let me know if this isn't clear.

ddadmin
11-24-2007, 01:28 AM
Inside the .js file, try finding the line:


this.dropmenuobj.style.left=this.dropmenuobj.x-this.clearbrowseredge(obj, "rightedge")+"px"

and changing that to:


this.dropmenuobj.style.left=this.dropmenuobj.x-(obj.offsetWidth/2)+"px"