function xmlhttpPostCollection(strURL) {    
	//alert(msg);
	var xmlHttpReqCollection = false;    
	var self = this;    // Mozilla/Safari    
	if (window.XMLHttpRequest) {        
		self.xmlHttpReqCollection = new XMLHttpRequest();    
	}else if (window.ActiveXObject) {      // IE    
		self.xmlHttpReqCollection = new ActiveXObject("Microsoft.XMLHTTP");    
	}
	self.xmlHttpReqCollection.open('POST', strURL, true);    
	self.xmlHttpReqCollection.setRequestHeader('Content-Type', 'application/x-www-form-urlencoded');    
	self.xmlHttpReqCollection.onreadystatechange = function() {        
		if (self.xmlHttpReqCollection.readyState == 4) {            
			updatepageCollection(self.xmlHttpReqCollection.responseText);        
		}    
	}    
	self.xmlHttpReqCollection.send();
}
function getquerystring(id) {  //设置传递参数
	var qstr = 'id=' + escape(id);  // NOTE: no '?' before querystring  
	return qstr;
}
function updatepageCollection(str){     //收藏以后  JS提示  操作的结果
	//sendRequest();
	//str=escape(str)
	alert(str.replace( /^\s*/, ""));
}
function collect(id){ //
	xmlhttpPostCollection("collection.jsp?id="+id);	
}
