function createCookie(name,value) {
	//add days as an argument if you want
	/*if (days) {
		var date = new Date();
		date.setTime(date.getTime()+(days*24*60*60*1000));
		var expires = "; expires="+date.toGMTString();
	}
	else 
	*/
	var expires = "";
	document.cookie = name+"="+escape(value)+expires+"; path=/";
}

function getWinLoc(){
	
		var cookieVal= document.location.search; 
		if(cookieVal){
			//alert(cookieVal)
			cookieVal = cookieVal.replace(/\?/,"&");
			createCookie('MyPoints',cookieVal);
		};
		
	}
	getWinLoc();