Ver Mensaje Individual
  #1 (permalink)  
Antiguo 25/06/2006, 20:59
Avatar de Wdeah
Wdeah
 
Fecha de Ingreso: julio-2005
Ubicación: Argentina
Mensajes: 109
Antigüedad: 18 años, 9 meses
Puntos: 0
Diferentes objetos

hola, alguien puede decirme que diferencia hay entre las siguientes 2 funciones...

Código PHP:
function XMLHTTPOBJ ()
{
 return (
typeof(XMLHttpRequest) != 'undefined') ? new XMLHttpRequest() : (typeof(ActiveXObject) != 'undefined' ? new ActiveXObject('Microsoft.XMLHTTP') : false);
}
 
function 
XMLHTTPOBJ ()
{
 try {
  
xmlhttpojb = new ActiveXObject("Msxml2.XMLHTTP");
 }
 catch (
e) {
  try {
   
xmlhttpojb = new ActiveXObject("Microsoft.XMLHTTP");
  }
  catch (
E){
   
xmlhttpojb false;
  }
 }
 if (!
xmlhttpojb && typeof XMLHttpRequest != 'undefined')
 {
  
xmlhttpojb = new XMLHttpRequest();
 }
 return 
xmlhttpojb;

saludos.