Results 1 to 2 of 2

Thread: Chrome CSS Drop Down Menu Question

  1. #1
    Join Date
    Jan 2007
    Posts
    181
    Thanks
    5
    Thanked 3 Times in 3 Posts

    Default Chrome CSS Drop Down Menu Question

    1) Script Title: Chrome CSS Drop Down Menu (v2.01)

    2) Script URL (on DD): http://www.dynamicdrive.com/dynamici...rome/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.

  2. #2
    Join Date
    Aug 2004
    Posts
    10,143
    Thanks
    3
    Thanked 1,008 Times in 993 Posts
    Blog Entries
    16

    Default

    Inside the .js file, try finding the line:

    Code:
    this.dropmenuobj.style.left=this.dropmenuobj.x-this.clearbrowseredge(obj, "rightedge")+"px"
    and changing that to:

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

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •