Ver Mensaje Individual
  #1 (permalink)  
Antiguo 05/06/2012, 07:08
warelo17
 
Fecha de Ingreso: mayo-2012
Mensajes: 28
Antigüedad: 12 años
Puntos: 0
local y subido al servidor

tengo un prbloma con un ajax cuando lo subo al servidor no me funciona y cuando lo pruebo local me funciona, cambio la ruta del jquery..
hay esta el código.
Código PHP:
Ver original
  1. <html>
  2.     <head>
  3.         <script type="text/javascript" src="../plugins/jquery-1.7.2.js"></script>
  4.     </head>
  5.  
  6.     <body>
  7.         <br>
  8.         <label>Nombre de Usuario:</label>
  9.         <input type="text" id="texto" />
  10.         <input  type= "button" value = "Consultar" id = "boton" />
  11.         <br></br>
  12.         <br></br>
  13.         <br></br>
  14.         <label>DATOS USUARIO</label>
  15.         <div id = "datos_usu">
  16.             <br></br>
  17.             <br></br>
  18.             <br></br>
  19.         </div>
  20.         <label>PERMISOS QUE POSEE</label>
  21.         <div id ="permiso">
  22.         <br></br>
  23.         </div>
  24.        
  25.         <script>
  26.             $(document).ready(function(e) {
  27.                 $('#boton').click(function(){
  28.                     var mensaje = $('#texto').val();
  29.                     alert(mensaje);
  30.                     $.ajax({
  31.                        
  32.                         type     : "GET",
  33.                         url      : "admin_urg_add.php",
  34.                         data     : "mensaje="+mensaje,
  35.                         cache    : false,
  36.                         success  : function(datos){
  37.                     alert("hola");
  38.                                 alert(datos);
  39.                                
  40.                         }
  41.                     });
  42.                 });
  43.             });
  44.         </script>
  45.     </body>
  46. </html>