function SNDABackPop(){
	this.PopUrl='';
	this.PopTimeSpan=1;
	this.PopWindowWidth='0';
	this.PopWindowHeight='0';
	this.PopKeyName='';
	this.PopType=1;//1--±³µ¯ 2--Ç°µ¯
	this.JsString='toolbar=yes,menubar=yes,scrollbars=yes,resizable=yes,location=yes,status=yes';
	this.exp=new Date();	
};
SNDABackPop.prototype.Initialize = function (PopUrl,PopTimeSpan,PopWindowWidth,PopWindowHeight,PopKeyName,PopType,JsString){
	this.PopUrl=PopUrl;
	this.PopTimeSpan=PopTimeSpan;
	this.PopWindowWidth=PopWindowWidth;
	this.PopWindowHeight=PopWindowHeight;
	this.PopKeyName=PopKeyName;	 
	this.PopType=PopType;
    this.JsString=JsString;  
	this.exp.setTime(this.exp.getTime() + (this.PopTimeSpan*60*1000));
};
SNDABackPop.prototype.GetCookie=function(name){
	var arg = name + '='; 
	var alen = arg.length; 
	var clen = document.cookie.length,i = 0; 
	while (i < clen) { 
		var j = i + alen; 
		if (document.cookie.substring(i, j) == arg)     return this.getCookieVal (j); 
		i = document.cookie.indexOf(' ', i) + 1; 
		if (i == 0) break; 
	}; 
	return null;
};
SNDABackPop.prototype.getCookieVal=function(offset) {
	var endstr = document.cookie.indexOf (';', offset);
	if (endstr == -1)   endstr = document.cookie.length;
	return unescape(document.cookie.substring(offset, endstr));
};
SNDABackPop.prototype.SetCookie=function(name, value) { 
    var argv = this.SetCookie.arguments; 
	var argc = this.SetCookie.arguments.length; 
	var expires = (argc > 2) ? argv[2] : null; 
	var path = (argc > 3) ? argv[3] : null; 
	var domain = (argc > 4) ? argv[4] : null; 
	var secure = (argc > 5) ? argv[5] : false; 
	document.cookie = name + '=' + escape (value) + ((expires == null) ? '' : ('; expires=' + expires.toGMTString())) + ((path == null) ? '' : ('; path=' + path)) + ((domain == null) ? '' : ('; domain=' + domain)) + ((secure == true) ? '; secure' : '');
};
SNDABackPop.prototype.DeleteCookie=function(name) { 
	var exp = new Date(),cval = 0; 
	exp.setTime (exp.getTime() - 1); 
	document.cookie = name + '=' + cval + '; expires=' + exp.toGMTString();
};
SNDABackPop.prototype.Pop=function(){
	if(this.GetCookie(this.PopKeyName) == null){
		this.SetCookie(this.PopKeyName,1,this.exp);
		this.paypopup();
	};
};
SNDABackPop.prototype.paypopup=function(){ 
	popwin = window.open(this.PopUrl,'newWindow',(this.PopWindowWidth>0?'width='+this.PopWindowWidth:'')+','+(this.PopWindowHeight>0?'height='+this.PopWindowHeight:'')+','+this.JsString);
	if (popwin)         poped = true;
	if(this.PopType==1) self.focus();  
};