Ver Mensaje Individual
  #4 (permalink)  
Antiguo 26/02/2012, 07:53
Avatar de pablovhau
pablovhau
 
Fecha de Ingreso: diciembre-2011
Mensajes: 16
Antigüedad: 12 años, 4 meses
Puntos: 0
Respuesta: chrome esta mal o yo estoy mal?

aqui esta el codigo, el css y el link con la pagina, y una muestra on line

[URL="http://www.vhau.cl/work/CON%20TAGS%20EJEMPLO%20si%20funciona.html"]http://www.vhau.cl/work/CON%20TAGS%20EJEMPLO%20si%20funciona.html[/URL]

Código:
<script>
$(document).ready(function() {
        var el = $('#sidebar-1'),
            top_offset = $('.container').offset().top;

        $(window).scroll(function() {
          var scroll_top = $(window).scrollTop();

          if (scroll_top > top_offset) {
            el.css('top', scroll_top - top_offset);
          }
          else {
            el.css('top', '0');
          }
        });
});
</script>

css

Código:
.container { float: left;
	width: 100%; margin: 0px 0px;
	 }
.main { float: left; width: 610px; margin: 0 2px; margin-left:230px; }
.sidebar { float: left; width: 180px; }
#sidebar-1 {
	position: relative;
	float: left;
	width: 180px; /*Width of left column*/
	font-family:Arial, Helvetica, sans-serif;
	margin-left:40px;
	
	width: 200px;
"> }

ahi estan los datos del code, no habia probado el demo desde internet y veo que pasa lo mismo

GRACIAS DE ANTEMANO