Solved

css drop menu

Posted on 2011-02-11
2
242 Views
Last Modified: 2012-05-11
HI Experts,

I have a xhtml/css drop menu that works just fine... unit it's placed in it's permanent position in the page. Because the menu is placed so close to the bottom of the browser window, the drop menu li elements get pushed into wierd positions and it looks terrible.  It seems that if a drop menu tries to open near the bottom of the browser window then it displays up instead of down and the positioning goes crazy.  Any ideas about how I can control the positioning when this happens?

Thanks,

HNM
0
Comment
Question by:HelpNearMe
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 34

Accepted Solution

by:
Paul MacDonald earned 250 total points
ID: 34874598
Surely the LI elements are being positioned themselves.  Can't you change the positioning to use negative X values?
0
 
LVL 14

Assisted Solution

by:Designbyonyx
Designbyonyx earned 250 total points
ID: 34874733
Just a note that it's not really the best usability option to have dropdown menus at the bottom of your site.

Usually, you just create tall lists:

(not sure if this will show up correctly... but you get the idea)

Top Item            Top Item
 - Sub Item           - Sub Item
 - Sub Item           - Sub Item
 - Sub Item           - Sub Item
 - Sub Item           - Sub Item

Open in new window



Or you could use something similar to @paulmacd's suggestion to create a "drop-up" menu.  If you post some code, I can write the CSS for you.  Instead of negative positioning, you will want to do something similar to this:

(Note: this style is not complete.  I will need to see your code to create the proper styles)

ul li {
    position: relative;
}
ul ul {
    position: absolute;
    bottom: -99999px;
}
ul li:hover ul {
    bottom: 0;
}

Open in new window

0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When it comes to write a Context Sensitive Help (an online help that is obtained from a specific point in state of software to provide help with that state) ,  first we need to make the file that contains all topics, which are given exclusive IDs. …
This article explains how to prepare an HTML email signature template file containing dynamic placeholders for users' Azure AD data. Furthermore, it explains how to use this file to remotely set up a department-wide email signature policy in Office …
In this tutorial viewers will learn how to embed videos in a webpage using HTML5. Ensure your DOCTYPE declaration is set to HTML5: "<!DOCTYPE html>": Use the <video> tag to insert a video. Define the src as the URL of your video; this is similar to …
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

691 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question