Ver Mensaje Individual
  #1 (permalink)  
Antiguo 16/07/2014, 13:53
plasma_go
 
Fecha de Ingreso: mayo-2014
Ubicación: Mexico
Mensajes: 79
Antigüedad: 10 años, 10 meses
Puntos: 2
Error al cargar ajax en internet explorer

Buenas tardes, estoy haciendo un proyecto y ocupo ajax, y necesito que al darle click a un calendario, me haga una carga de los horarios disponibles. Todo bien hasta que lo pruebo en internet explorer y me sale el siguiente error:


Detalles de error de página web

Agente de usuario: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1; Trident/4.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; InfoPath.3; .NET4.0C; .NET4.0E)
Fecha: Wed, 16 Jul 2014 19:57:08 UTC


Mensaje: Error desconocido en tiempo de ejecución
Línea: 30
Carácter: 4
Código: 0
URI: http://localhost/m/funciones/ajax.js

Y aqui les dejo el codigo de ajax

Código Javascript:
Ver original
  1. function objetoAjax(){
  2.     var xmlhttp=false;
  3.     try {
  4.         xmlhttp = new ActiveXObject("Msxml2.XMLHTTP");
  5.     } catch (e) {
  6.         try {
  7.            xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");
  8.         } catch (E) {
  9.             xmlhttp = false;
  10.         }
  11.     }
  12.  
  13.     if (!xmlhttp && typeof XMLHttpRequest!='undefined') {
  14.         xmlhttp = new XMLHttpRequest();
  15.     }
  16.     return xmlhttp;
  17. }
  18.  
  19. function MostrarConsulta(datos){
  20.     divResultado = document.getElementById('resultado');
  21.     ajax=objetoAjax();
  22.     ajax.open("GET", datos);
  23.     ajax.onreadystatechange=function() {
  24.         if (ajax.readyState==4) {
  25.             divResultado.innerHTML = ajax.responseText
  26.         }
  27.     }
  28.     ajax.send(null)
  29. }