[QUOTE=electriduct;114113]Hi,
I'm working since few days to design a vertical menu for my website. To make it search engine friendly, I use CSS.
However, I'm having some trouble to do some tasks.
1)I would like for only some of the items, add an arrow on the right in the background.
Code:
div#menu ul li.arrow {
padding-right: 20px;
background: transparent url('/path/to/arrow') no-repeat right;
}
where case items are <li class="arrow">
2)make the second level overlap the first one when it's display by the mouse over a category.
Code:
div#menu ul li:hover ul {
display: block;
position: relative;
top: -10px; /* in reference to where you want the dropout to be */
left: -10px;
}
Code:
<div id="menu">
<ul>
<li>Link
<ul>
<li>Sub Link</li>
<li>Sub Link</li>
<li>Sub Link</li>
</ul>
</li>
</ul>
note this will not work with IE6 you must use a Javascript Hack
3)I would like to keep the light background on the category when I"m moving the mouse over the second level
Code:
div#menu ul li {
background-color: #hexcolor;
}
or
div#menu ul li {
background: transparent url('/path/to/background/image') repeat;
}
4)I would like when someone is in the category 2, the category 2 in the menu is lighter, like the mouse over. I read that it should be able to do it with Javascript but i would like a simple way to do it.
Code:
ul li a:hover {
display: block; /* makes the link the entire width of the list item */
background-color: #hexcolor;
}
this will work for hovering over all list items with links if you want to make it for just this specific menu, add the div#menu
or whatever menu at the beginning of the line
5)I test my menu in IE 7.0 and Mozilla, but I'm sure about IE 6.0 (55% client use IE 6 on my website). And though not a lot use IE 5 or older version, I would still want to fix the bugs for these versions.
IE6 is going to cause alot of problems as the web continues to develop. Until IE6 becomes obsolete there will be a number of problems with CSS support due to Microsoft not being able to abide by industry standards.
Bookmarks