Ver Mensaje Individual
  #1 (permalink)  
Antiguo 28/06/2013, 16:06
malcubas1
 
Fecha de Ingreso: noviembre-2012
Mensajes: 14
Antigüedad: 11 años, 5 meses
Puntos: 0
Exclamación menu tipo acordeon

si alguien me puede ayudar nesecito hacer tipo acodeon el siguiente menu

gracias

Código HTML:
<div id="divmenu">
<ul class="top-level">
<li id="1" name="1">
<a href="#">Gestion Academica papa</a>
<ul class="sub-level">
<li id="2" name="2">
<a href="#">Proceso de Matricula hijo</a>
<ul class="sub-level">
<li id="7" name="7">
<a href="#">Carga Academica nieto</a>
</li>
<li id="8" name="8">
<a href="#">Cursos Matriculados nieto</a>
</li>
<li id="10" name="10">
<a href="#">Reportes nieto</a>
</li>
</ul>
</li>
<li id="3" name="3">
<a href="#">Proceso de Notas hijo</a>
<ul class="sub-level">
<li id="9" name="9">
<a href="#">Registro de Notas nieto</a>
</li>
</ul>
</li>
<li id="4" name="4">
<a href="#">R nieto</a>
</li>
</ul>
</li>
<li id="5" name="5">
<a href="#">Gestion Administrativa papa</a>
<ul class="sub-level">
<li id="6" name="6">
<a href="#">ventas nieto</a>
</li>
</ul>
</li>
</ul>
</div> 

Código CSS:
Ver original
  1. #divmenu { font-size:0.75em; width:200px; }
  2. #divmenu ul { margin:0px; padding:0px; }
  3. #divmenu li { list-style: none; }
  4.  
  5. ul.top-level { background:#666; }
  6. ul.top-level li {
  7.  border-bottom: #fff solid;
  8.  border-top: #fff solid;
  9.  border-width: 1px;
  10. }
  11.  
  12. #divmenu a {
  13.  color: #fff;
  14.  cursor: pointer;
  15.  display:block;
  16.  height:25px;
  17.  line-height: 25px;
  18.  text-indent: 10px;
  19.  text-decoration:none;
  20.  width:100%;
  21. }
  22.  
  23. #divmenu a:hover{
  24.  text-decoration:underline;
  25. }
  26.  
  27. #divmenu li:hover {
  28.  background: #f90;
  29.  position: relative;
  30. }
  31. ul.sub-level {
  32.     display: none;
  33. }
  34. li:hover .sub-level {
  35.     background: #999;
  36.     border: #fff solid;
  37.     border-width: 1px;
  38.     display: block;
  39.     position: absolute;
  40.     left: 75px;
  41.     top: 5px;
  42. }
  43. ul.sub-level {
  44.     display: none;
  45. }
  46.  
  47. li:hover .sub-level {
  48.     background: #999;
  49.     border: #fff solid;
  50.     border-width: 1px;
  51.     display: block;
  52.     position: absolute;
  53.     left: 75px;
  54.     top: 5px;
  55. }
  56.  
  57. ul.sub-level li {
  58.     border: none;
  59.     float:left;
  60.     width:150px;
  61. }
  62.  
  63. /*Seconda Level*/
  64. #divmenu .sub-level {
  65.     background: #999;
  66. }
  67.  
  68. /*Third Level*/
  69. #divmenu .sub-level .sub-level {
  70.     background: #09C;
  71. }
  72. /*RESET STYLES*/
  73. li:hover .sub-level .sub-level {
  74.     display:none;
  75. }
  76.  
  77. .sub-level li:hover .sub-level {
  78.     display:block;
  79. }