function Http(method,url,vars,async,callEval){
	try {this._socket = new XMLHttpRequest();}catch(e){try{this._socket=new ActiveXObject('Microsoft.XMLHTTP');}catch(e){try{this._socket=new ActiveXObject("Msxml2.XMLHTTP");}catch(e){this._socket=false;}}}
	this._method=method;
	this._url=url;
	this._vars=vars;
	this._async=async;
	this._callEval=callEval;
	this._response=null;
	this._status=null;
	this._aborted=false;
	Http.prototype.fireOnError=function(){};
	Http.prototype.fireOnSuccess=function(){};
}
Http.prototype.run=function(){
	try{
		var s = this._socket;
		var o = this;
		s.onreadystatechange=function(){
			if(s.readyState==4){
				o._status = s.status;//alert(s.responseText);
				if(s.status<300){
					try{
						if(o._callEval){
							eval(s.responseText);
						}else{
							o._response=s.responseText;
						}
					}catch(e){
						o.fireOnError(e.message);
						return;
					}
				}else{
					if(!o._aborted){
						o.fireOnError("Sunucu Hatası!");
					}
					return;
				}
				o.fireOnSuccess();
			}
		};
		s.open(this._method,this._url,this._async);
		s.setRequestHeader('Content-Type','application/x-www-form-urlencoded;charset=UTF-8');
		s.send(this._vars);
	}catch(e){
		this.fireOnError(e.message);
	}
	return true;
}
Http.prototype.onError=function(f){Http.prototype.fireOnError=f;}
Http.prototype.onSuccess=function(f){Http.prototype.fireOnSuccess=f;}
Http.prototype.getStatus=function(){return this._status;}
Http.prototype.getResponse=function(){return this._response;}
Http.prototype.abort=function(){try{this._aborted=true;this._socket.abort();}catch(e){}}
