Ver Mensaje Individual
  #6 (permalink)  
Antiguo 02/07/2011, 00:51
Avatar de ArturoGallegos
ArturoGallegos
Moderador
 
Fecha de Ingreso: febrero-2008
Ubicación: Morelia, México
Mensajes: 6.774
Antigüedad: 16 años, 2 meses
Puntos: 1146
Respuesta: Como cambiar atributos en botones css

aunque ciertamente cometí un error en el código anterior, este no afecta al mostrar la imagen... acabo de probar el código y funciona perfectamente... le dejo el código tal cual lo he implementado.

mi error estuvo en text-indent:100px; debió de ser en negativo -> text-indent:-100px;

y el codigo que con el que acabo de probar fue:

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" xml:lang="en" lang="en">
  3.  
  4.     <meta http-equiv="content-type" content="text/html; charset=iso-8859-1" />
  5.     <meta name="author" content="Ag666" />
  6.     <title>Untitled 1</title>
  7. <style type="text/css">
  8.     .cinco a {
  9.         display:block;
  10.         width:35px;
  11.         height:35px;
  12.         text-indent:-100px;
  13.         text-decoration: none;
  14.         background: url(http://dl.dropbox.com/u/33016972/icon2.png) no-repeat center center;
  15.     }
  16.     .cinco a:hover {
  17.         width:40px;
  18.         height:40px;
  19.         background-image: url(http://dl.dropbox.com/u/33016972/icon1.png);
  20.     }
  21. </head>
  22.  
  23.     <div class="cinco">
  24.     <a href="url">url</a>
  25.     </div>
  26.  
  27. </body>
  28. </html>