Ver Mensaje Individual
  #3 (permalink)  
Antiguo 09/06/2011, 12:45
Avatar de emprear
emprear
Colaborador
 
Fecha de Ingreso: junio-2007
Ubicación: me mudé
Mensajes: 8.388
Antigüedad: 16 años, 10 meses
Puntos: 1567
Respuesta: "Problema de alineaciones en div"

Asi como lo haces no vas a ninguna parte
Porá con esto

Código HTML:
Ver original
  1. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
  2.    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  3. <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="es" lang="es">
  4. <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
  5. <title>alinear</title>
  6. </head>
  7. <img src='cat-black.jpg' width="320" height="400"  alt="" style="float: left;border: solid 1px #000;"/>
  8. <div style="float: left; width:320px; height: 400px;border: solid 1px #000;text-align:center; vertical-align: middle; line-height: 400px; font-family: arial,verdana,serif; font-size:22pt;">
  9. Descripción</div>
  10. </body>
  11. </html>


Tenés que definir los altos y anchos

Demo
http://foros.emprear.com/css/alinear.html

y es recomendable que pases los styles a css

Saludos
__________________
La voz de las antenas va, sustituyendo a Dios.
Cuando finalice la mutación, nueva edad media habrá
S.R.