unordered-list

menu as unordered list horizontally or table?

I have an unordered list I'm displaying horizontally as the page's top menubar. I've gotten it to display relatively well, although I've been playing with the spacing for IE6 and IE7 cause it's not displaying properly. Shocking. In either case, is it better to use a table to display the menu or use some CSS hacks, which I can't find a...

Styling unordered horizontal list with ...best possible way

To make lists horizontal and hide default bullets, is it necessary to give {display:inline} and {float:left} both to the <li> tags or anyone of these alone is enough? <ul> <li><a href="#">First item</a></li> <li><a href="#">item 2</a></li> <li><a href="#">item 3</a></li> <li><a href="#">item 4</a></li> <li><a href="#">Last item</a></li...

dropdown unsorted list css - vertical issue

hello I have a css script for unsorted list (vertical) drop down list that has two problem- 1. in ie7 it shifts. 2. the first sub menu, the top positions is not leveled with the main level. (the second sub menu is fine). here is the code : #nav, #nav ul { margin: 0; padding: 0; list-style-type: none; list-style-positio...

Mapping an array of records with depth values into nested Unordered List

Hi there, I hope this question hasn't been asked before: I'm using the ancestry gem to manage my tree structure. I'm using a function which returns the descendants of a node to a certain number of levels. Here's a simplistic example of what it's returning: [{:name => 'node 1', :depth => 1}, {:name => 'node 2', :depth => 2} {:name => '...

Rendering an unordered list using asp.net

Hi everyone, I need to render a unordered list with the data obtained from database using asp.net/C#.My data looks something like this. id Name Depth 1 ELECTRONICS 0 2 TELEVISIONS 1 3 Tube 2 4 LCD 2 5 Plasma 2 6 Portable...

a bug in ie7 - body -direction:rtl

When i set the body element direction to rtl, in ie7 (compatability view in ie8), and hover over ul li , it shifts wierdly to the left by a couple of inches. a good example for this is the default asp.net mvc css (after adding direction:rtl to the body elemet. anyone know this one? the example code: /*-------------------------------...

Is it possible to make Unordered list like this using CSS ?

Hi, Is it possible top make an unordered list in this image ? I cant use 2 images for single <li> tag If I use arrow as background and padding-left then the border-bottom will come under image as well. I cant use margin-left and background-position too I guess ? Any ideas ? Thanks ...

jquery selecting all last elements of an nested tree menu unordered list...not just the :last-child...

I'm having some trouble figuring this out. I have an unordered list menu that I want to style all the last elements with a folder icon and style all the expandable (parent) elements with a plus.gif image. I wanted to simply change the class by using .addclass() using jquery, which will contain the css to add the background-image. My j...

Create unordered list tree menu from data stored in an table with the adjacency list model...php

I need to create a tree menu of "nth" subcategories. I settled on using the adjacency list model for my table structure, because I won't be updating this table very much and this seemed the easiest to implement for my use. I want to style the output using "ul" and "li" tags...I already have a css and jquery solution to do the styling...

Subnav "active" when it shouldn't be.

http://wilwaldon.com/itsbroken/templateleftnav.php As you can see on the left navigation the link for Template 01 is highlighted green. The link underneath is also highlighted green. I think the problem lies with the initial LI controlling the ul underneath somehow. I need to keep the xhtml formatted exactly how it is right now and o...

How can I position some divs inside an unordered list so they line up with the root element of the list?

I want to position all the divs to line up to the left on the same x coordinate so it looks nice. Notice the picture below, how based on the number of nested categories the div (and its contents) show up at slightly different x coordinates. I need to have the div's line up at exactly the same x coordinate no matter how deeply nested. N...

jquery - How do I get the attribute of the root, or top most < li > if I'm nested deeply down in an unordered list...

I want walk back up the tree menu of a nested unordered list to the top most < li > and retrieve the "p_node" attribute using the toggle function of jquery. So, for example, when I click on "Annie" I want to retrieve the root li, which in her case is "mCat1" and extract the value for "p_node" to be used in the script. How can I accompli...

jQuery CSS menu not selecting the active link

What is wrong with this and how could I fix it? I have a CSS menu (horizontal) that I want the background and font to be changed when one of the items is selected. I found another post that gave me some jQuery code to help make it work, and I thought I had it coded right, but when I click on an item to change its class it adds the clas...

Parent and siblings inherits a child list items styles

I have a simple menu <ul id="menu"> <li class="leaf"><a href="#">Menu Item 1</a></li> <li class="leaf"><a href="#">Menu Item 2</a></li> <li class="expanded"><a href="#">Menu Item 3</a> <ul> <li class="leaf"><a href="#">Menu Item a</a></li> <li class="leaf"><a href="#">Menu Item b</a></li> <li class="leaf"><a hre...

Why is this unordered list formatting differently in IE7?

I'm better about getting things to look good in IE8, FF, and Safari, but IE7 still throws curve balls at me... Please check out this page and scroll down below the nav bar: http://rattletree.com/instruments.php It should become obvious when viewing in FF vs IE7. For some reason the formatting of the list is pushing the list items down...

how to make css submenu stay put when subpage has been selected.

I have a css horizontal menu with a menu / submenu display working on the hover, but I would also like to make the submenu options stay put when I've selected that page. The code below shows the submenu on hover, but goes away on mouse out. I'm having some difficulty figuring out how to make my code work to keep the submenu items stayi...

Add a different ID to each li element by jQuery

Hi guys, I'm new here and I'd like to ask a question about jQuery. I have the unordered list like: <ul id="pages"> <li class="something"><a href="#"></a></li> <li class="something"><a href="#"></a></li> <li class="something"><a href="#"></a></li> </ul> And I'd like to add a different ID to every li displayed in this <ul> ...

Help with PHP recursive navigation list menu

Hi all, I am trying to add a dynamic recursive navigation list menu to a site of am working on. The scenerio is that the menu has 2 levels related by a parentid(preid). My issue is that I can display the 1st level list correctly, however I cannot get the second level to display properly. I am not sure where to add the UL and /UL tags f...

Populating a UL with Jquery

Hi Guys, I'm a little bit stumped with this UL I'm building. I've been able to populate the list no problem but it's all messed up when it comes to formatting. Here's my script: $.ajax({ type: "GET", url: "/shop/assets/xml/tonneau_makes.xml", dataType: "xml", success: function(xml) { var selectInfo = $("li.select...

Presentation Issue in an Unordered List

I'm having an issue with correctly presenting items in an unordered list. The labels are floating left and the related spans that are long in length are wrapping and showing below the label. I need a solution that keeps the related spans in their respective columns. In other words, I don't want long spans to show under the labels. Wh...