function removeTopic(topicId,e){
	try{
		if(event!=undefined){
			e=event
		}
	}catch(ex){}
	m=getMouseIntXY(e);
	this.x=m[0];
	this.y=m[1];
	
	this.pageContainer=$('body');
	if(window.innerHeight){ 
		this.height=window.innerHeight;
		this.width=window.innerWidth;
		
	}else{
		this.height=document.body.clientHeight;
		this.width=document.body.clientWidth;
	}
	this.id=topicId;
	
	if(confirm('Искате ли да изтриете тази тема?')){
		this.remove();
	}
}

removeTopic.prototype.remove=function(){
	this.xmlHttp_remove = getXML();
	this.xmlHttp_remove.obj=this.obj;
	
	this.xmlHttp_remove.onreadystatechange = this.handelRemove;

	var send=Object();
	send.operation='removeTopic';
	send.id=this.id;
	post= escape(prepearVar2(send));
	var string=base+"ajax/cms/forum/common/"+send.operation+"?js="+post;
	this.xmlHttp_remove.open("GET",string,true);
	this.xmlHttp_remove.send(post);
	return false;
}
removeTopic.prototype.handelRemove=function (){
	if(this.readyState==4){
		alert(this.responseText);
		var jsonvar = Object();
		try{jsonvar=eval('(' + this.responseText + ')');
		}catch(ex){alert('Вътрешна грешка: Сървърът не отговаря!'+ex);return;}
		if(jsonvar.status!='ok'){alert('Транспортна грешка: Няма връзка със сървъра!');return;}
		window.location=base+lang+'/'+full_url;
	}
}
