Created
May 18, 2011 04:48
-
-
Save maxim75/978011 to your computer and use it in GitHub Desktop.
Rollover menu (somewhat similar to accordion)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" | |
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> | |
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en" | |
<head> | |
<style> | |
ul.acclist | |
{ | |
border: solid 1px Black; | |
list-style: none; | |
margin: 0; | |
padding: 0; | |
cursor: pointer; | |
} | |
ul.acclist li | |
{ | |
padding: 0; | |
margin: 0; | |
border-bottom: 1px dotted #CCCCCC; | |
} | |
ul.acclist li p | |
{ | |
padding: 5px; | |
margin: 0; | |
} | |
ul.acclist ul | |
{ | |
margin: 0; | |
padding: 0; | |
list-style: none; | |
} | |
ul.acclist ul | |
{ | |
display: none; | |
} | |
ul.acclist ul li | |
{ | |
padding: 0 0 0 10px; | |
border: none; | |
} | |
ul.acclist li:hover ul | |
{ | |
display: block; | |
} | |
ul.acclist li:hover | |
{ | |
background-color: #eeeeee; | |
} | |
ul.acclist ul li:hover | |
{ | |
background-color: #cccccc; | |
} | |
</style> | |
</head> | |
<body> | |
<ul class="acclist"> | |
<li> | |
<p>One</p> | |
<ul> | |
<li><a href="#">1.1</a></li> | |
<li><a href="#">1.2</a></li> | |
</ul> | |
</li> | |
<li> | |
<p>Two</p> | |
<ul> | |
<li><a href="#">1.1</a></li> | |
<li><a href="#">1.2</a></li> | |
</ul> | |
</li> | |
<li> | |
<p>Three</p> | |
<ul> | |
<li><a href="#">1.1</a></li> | |
<li><a href="#">1.2</a></li> | |
</ul> | |
</li> | |
</ul> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment