Results 1 to 5 of 5

Thread: CSS Chrome Menu menus go up instead of down?

  1. #1
    Join Date
    Nov 2007
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default CSS Chrome Menu menus go up instead of down?

    1) Script Title: Chrome CSS Drop Down Menu

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

    3) Describe problem: I have this script up and working and love it. I am wondering if it is possible to have the drop down menus go upward, instead of downward. With the layout of the site, it would be beneficial to have them all go up instead. I am not sure if this is possible.

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

    Default

    Do you mean always drop upwards, regardless of whether there's enough space below the menu (or enough space above, for that matter)? Right now the menus actually will drop up if there isn't enough viewable space below the menu bar...

  3. #3
    Join Date
    Nov 2007
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Thanks for the quick reply.

    Yes, I would like them to always drop upwards

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

    Default

    Sure, inside the .js file, just find the lines:

    Code:
    this.dropmenuobj.style.left=this.dropmenuobj.x-this.clearbrowseredge(obj, "rightedge")+"px"
    this.dropmenuobj.style.top=this.dropmenuobj.y-this.clearbrowseredge(obj, "bottomedge")+obj.offsetHeight+1+"px"
    and change them to:

    Code:
    this.dropmenuobj.style.left=this.dropmenuobj.x+"px"
    this.dropmenuobj.style.top=this.dropmenuobj.y-this.dropmenuobj.offsetHeight+1+"px"

  5. #5
    Join Date
    Nov 2007
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Thanks for your help, it is greatly appreciated.

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
  •