Ver Mensaje Individual
  #4 (permalink)  
Antiguo 27/02/2012, 10:43
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: sidebar fixed ...

Bueno, todo sea por el beneficio de la duda...
amigo @pablovhau, tu fixed hace exactamente lo que corresponde, la forma correcta, e ideal (digo ideal porque debería funcionar igual en el cadavérico ie6), es:

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">
  4. <title>Fixed izquierda</title>
  5. <meta http-equiv="content-type" content="text/html; charset=utf-8" />
  6. <style type="text/css">
  7.  body{
  8.   margin:0;
  9.   padding:0 0 0 250px;;
  10.  }
  11.  div#menu{
  12.   position:absolute;
  13.   top:0;
  14.   left:0;
  15.   width:250px;
  16.   height:500px;
  17.   background-color: yellow;
  18.  }
  19.  @media screen{
  20.   body>div#menu{
  21.    position:fixed;
  22.   }
  23.  }
  24.  * html body{
  25.   overflow:hidden;
  26.  }
  27.  * html div#contenido{
  28.   height:100%;
  29.   overflow:auto;
  30.  }
  31. </head>
  32.  
  33. <div id="menu"> menu </div>
  34. <div id="contenido"> contenido
  35. </div>
  36.  
  37. </body>
  38. </html>

notá que el padding del body es igual al ancho del div del menu

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