Ver Mensaje Individual
  #2 (permalink)  
Antiguo 24/02/2012, 15:21
oliverarthurnardi
 
Fecha de Ingreso: noviembre-2010
Ubicación: aun no se donde vivir
Mensajes: 112
Antigüedad: 13 años, 6 meses
Puntos: 3
Respuesta: Porque esto no me funciona en Chrome

Cita:
Iniciado por oliverarthurnardi Ver Mensaje
me funciona en todos, hasta en IE6. Me he quedado un poco flipado cuando me funciono en IE6 y el chrome no me funciona. No se que puede ser. Espero que me podeís ayudar. Un saludo a todos.

Código Javascript:
Ver original
  1. <script type="text/javascript">
  2.  
  3. $(document).ready(function() {
  4.  
  5.     $('#home').click(function(){
  6.         $('#footer').hide();
  7.         $('html').animate({scrollTop: '0'}, 'slow');
  8.         return false;
  9.     });
  10.    
  11.     $('.lista1').click(function(){
  12.         $('#footer').hide();
  13.         $('html').animate({scrollTop: '1114px'}, 'slow');
  14.         return false;
  15.     });
  16.  
  17.    
  18.     $('.lista').click(function(){
  19.         $('#footer').hide();
  20.         $('html').animate({scrollTop: '2138px'}, 'slow');
  21.         return false;
  22.     });
  23.    
  24.     $('#contact1').click(function(){
  25.         $('#footer').show();
  26.         $('html').animate({scrollTop: '3412px'}, 'slow');
  27.         return false;
  28.     });
  29.     $('html').animate({scrollTop: '0'}, 0);
  30.     $('#footer').hide();
  31.    
  32.  
  33.  
  34. });
  35. </script>
bueno este es el html:
Código HTML:
Ver original
  1. <div id="layout">
  2. <header id="header">
  3.   <nav id="nav">
  4.   <ul>
  5.   <li id="home" class="lis"><a href="/"><span>Home</span></a></li>
  6.   <li class="lista1 lis"><a href="/"><span>About me</span></a></li>
  7.   <li class="lista lis"><a href="/"><span>Proyect</span></a></li>
  8.   <li id="contact1" class="lis"><a href="/"><span>Contact</span></a></li>
  9.   </ul>
  10.   </nav>
  11. <!--Start section intro-->
  12. <section id="intro" style="element.style background-position:center 0;}">
  13.   <div class="content">
  14.     <nav class="sub-nav">
  15.       <ul>
  16.         <li class="lista list"><a href="/"><span>Proyect</span></a></li>
  17.         <li class="lista1 list"><a href="/"><span>About me</span></a></li>
  18.       </ul>
  19.     </nav>
  20.   </div>
  21. </section><!--End section intro-->
  22. <!--Start section about-me-->
  23. <section id="about"></section><!--End section about-me-->
  24. <!--Start section work-->
  25. <section id="work"></section><!--End section work-->
  26. <!--Start section Contact-->
  27. <section id="contact"></section><!--End section Contact-->
  28. <footer id="footer"> </footer>
  29. </div><!--End id layout-->
  30. </body>
  31. </html>