Ver Mensaje Individual
  #19 (permalink)  
Antiguo 11/04/2008, 12:23
Avatar de MaBoRaK
MaBoRaK
 
Fecha de Ingreso: abril-2003
Ubicación: La Paz - Bolivia
Mensajes: 2.003
Antigüedad: 21 años
Puntos: 35
Re: Ejemplo Javascript orientado a objetos

loading..............

Algo que puedes hacer es.

Cita:
this.process=function()
{
this.ajax=new this.xmlHttp();
this.ajax.open(this.options.method,this.options.ur l+"?"+this.options.parameters,true);
this.ajax.setRequestHeader("Content-Type", this.options.contentType);
var oThis=this;
this.ajax.onreadystatechange=function(){return oThis.ready();}
this.ajax.send(this.options.parameters);
return this;
};
this.ready=function()
{
alert(this.ajax.readyState);
return this;
};
this.xmlHttp=function()
{
var xmlHttp;
try { xmlHttp=new XMLHttpRequest();return xmlHttp; }
catch (e) { try { xmlHttp=new ActiveXObject('Msxml2.XMLHTTP');return xmlHttp; }
catch (e) { try { xmlHttp=new ActiveXObject('Microsoft.XMLHTTP');return xmlHttp; }
catch (e) { alert('Your browser does not support AJAX!');return false; }}}
};
connection closed.
__________________

Maborak Technologies