Tema: Menu en Css
Ver Mensaje Individual
  #4 (permalink)  
Antiguo 06/04/2009, 08:27
Avatar de willyfc
willyfc
 
Fecha de Ingreso: octubre-2008
Ubicación: Santa Cruz - Bolivia
Mensajes: 662
Antigüedad: 15 años, 6 meses
Puntos: 40
Respuesta: Menu en Css

no entiendo bien lo que quieres hacer, si lo que quieres es que obtenga un color cuando estes sobre el tendrías que declararlo de esta manera:

Código html:
Ver original
  1. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  2. <html xmlns="http://www.w3.org/1999/xhtml">
  3. <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
  4. <title>Documento sin t&iacute;tulo</title>
  5. <style type="text/css">
  6. .contenedor{width:300px; height:200px; border:1px solid #333;}
  7. .contenedor a{color:#666; text-decoration:none;}
  8. .contenedor a:hover{color:#990000; text-decoration:underline;}
  9. .contenedor a:focus{color:#990000; text-decoration:underline;}
  10. .contenedor a:active{color:#990000; text-decoration:underline;}/*explorer*/
  11. </head>
  12.  
  13. <div class="contenedor">
  14.     <a href="#">vinculo 1</a><br />
  15.     <a href="#">vinculo 2</a><br />
  16.     <a href="#">vinculo 3</a><br />
  17. </div>
  18. </body>
  19. </html>

de esta manera resaltará cuando hagas o click o cuando adquiera el foco(puedes probarlo navegando con tab).

la otra posible opción que entiendo es que quieres que resalte cuando estes en esa sección:

Código:
<style type="text/css">
.contenedor{width:300px; height:200px; border:1px solid #333;}
.contenedor a{color:#666; text-decoration:none;}
.contenedor a:hover{color:#990000; text-decoration:underline;}
.contenedor a:focus{color:#990000; text-decoration:underline;}
.contenedor a:active{color:#990000; text-decoration:underline;}/*explorer*/
.contenedor a.current{color:#336699; text-decoration:none;}
</style>

<a href="#" class="current">vinculo 1</a><br />
y sucesivamente asignas la clase current a la sección donde estes navegando, la siguiente sección sería:

Código:
<a href="#" class="current">vinculo 2</a><br />
y se la quitarías al vínculo 1 y así sucesivamente, solo un vínculo a la vez tendría que tener la clase current dependiento de la sección donde estes
__________________
WFC
codigo82