Foros del Web » Creando para Internet » HTML »

no me pasa el script

Estas en el tema de no me pasa el script en el foro de HTML en Foros del Web. tengo unos problemas en el script no me pasa por los if @import url("http://static.forosdelweb.com/clientscript/vbulletin_css/geshi.css"); Código PHP: Ver original < html >         ...
  #1 (permalink)  
Antiguo 04/07/2012, 09:04
 
Fecha de Ingreso: mayo-2012
Mensajes: 28
Antigüedad: 12 años
Puntos: 0
no me pasa el script

tengo unos problemas en el script no me pasa por los if
Código PHP:
Ver original
  1. <html>
  2.    
  3.     <head>
  4.     <script type="text/javascript" src="../jquery-1.7.2.js" ></script>
  5.     <link href="css/movimientos.css"  rel="styleSheet" type="text/css"/>
  6.     <title>..:MOVIMIENTOS DE SOPORTE:.. </title>
  7.     </head>
  8.     <body>
  9.          <script>
  10.              alert("hola");
  11.              $("#contrasena").keypress(function(e){
  12.                 if(e.keyCode==13){
  13.                     alert("hola");
  14.                     verifica();
  15.                 }  
  16.              });
  17.         function verifica(){
  18.             if ($("#usuario").val() == "felipe"&& $("#contrasena").val() == "felipe"){
  19.                
  20.                 alert("usuario correcto");
  21.                
  22.                
  23.             }
  24.             else{
  25.                 alert("usuario incorrecto");
  26.            
  27.            
  28.         };
  29.            
  30.            
  31.         };
  32.        
  33.    
  34.         </script>
  35.         <div id="cajon" style="padding: 19px; margin: 411px; margin-top:177px; border: 1px solid #B4CADE; background-color:#E6EAED">
  36.             <table>
  37.                 <tr>
  38.             <label style="float:left " class="labels_grandes">NOMBRE DE USUARIO:<input style=" margin-left: 30px; " id="usuario" type="text" /></label>
  39.                 </tr>
  40.         <br>
  41.                 <br>
  42.                 <tr>
  43.                 <label style="float:left" class="labels_grandes">CONTRASE&#209A: <input style=" margin-left: 86px; "   id="Contrasena" type="password"  /></label>
  44.            </tr>
  45.         <br>
  46.                 <br>
  47.                 <tr>
  48.                 <div class="hhha_btn_blue" style="float:right; margin-left:100px; margin-right: 250px;">
  49.                 <a id="boton_buscar_usu" type="buton" style="cursor: pointer"  class="hhha_link" onclick="veirifica();" style="background-color: rgb(94, 118, 168); border-top-width: 1px; border-top-style: solid; border-top-color: rgb(142, 161, 199); ">Ingresar</a>
  50.                 </tr>
  51.            
  52.                 </div>
  53.        
  54.         <div style="clear:both"></div>
  55.                 </table>
  56. </div>
  57.        
  58. </body>
  59. </html>

si alguien me puede ayudar gracias
  #2 (permalink)  
Antiguo 04/07/2012, 13:58
Avatar de maycolalvarez
Colaborador
 
Fecha de Ingreso: julio-2008
Ubicación: Caracas
Mensajes: 12.120
Antigüedad: 15 años, 9 meses
Puntos: 1532
Respuesta: no me pasa el script

keyCode no es soportado por algunos navegadores, consulte sobre como manejar eventos del teclado crossbrowser, reporte el tema para que sea movido al foro de javascript
__________________
¡Por favor!: usa el highlight para mostrar código
El que busca, encuentra...

Etiquetas: css, input, link, botones
Atención: Estás leyendo un tema que no tiene actividad desde hace más de 6 MESES, te recomendamos abrir un Nuevo tema en lugar de responder al actual.
Respuesta




La zona horaria es GMT -6. Ahora son las 00:53.