var WitnessDlg = {
	type : 0,
	post_id : 0,
	address : '',
	showDlg:function(type, post_id, address) {	
	  var isShow = false;
		if (! $('divwitness')) {
			var tempDiv   =   document.createElement('div'); 
			tempDiv.id = "divwitness";
			tempDiv.style.cssText = "z-index:99999;position:absolute; left:0px; top:0px; background-color:transparent;width:571px!important;width:571px;height:358px;";
			document.body.appendChild(tempDiv);   
			tempDiv.innerHTML='<div id="DlgTitle" class="DlgTitle WitnessDlg dealTitle"><h1>成交回報</h1><div class="DlgClose" onclick="WitnessDlg.closeDlg();" title="關閉"></div></div><iframe id="ifwitness" name="ifwitness" width="100%" frameborder="0" scrolling="no" height="100%" src="index.php?module=userCenter&action=witness&type='+type+'&post_id='+post_id+'&address='+myencode(address)+'" style="border:2px solid #b3d1fe;" onload="$(\'ifwitness\').contentWindow.document.body.bgColor=\'#FFFFFF\'"></iframe>';
			Drag.init($('DlgTitle'), $('divwitness'));	
		} else {
			isShow = true;
			$('ifwitness').src = "index.php?module=userCenter&action=witness&type="+type+"&post_id="+post_id+'&address='+myencode(address);
		}
		this.setPosition($('divwitness'));
		$('divwitness').style.display = '';
		this.type = type;
		this.post_id = post_id;
		this.address = address;
		if (isShow) {
			$('ifwitness').contentWindow.setInfo();
		}
	},
	setPosition:function(obj) {		
		if (self.innerHeight) {	// all except Explorer
			windowHeight = self.innerHeight;
		}	else {
			windowHeight = document.documentElement.clientHeight;
		}
		obj.style.left = (document.documentElement.clientWidth - parseInt(obj.style.width))/2 + 'px';
		obj.style.top = document.documentElement.scrollTop + (windowHeight - parseInt(obj.style.height))/2 + 'px';
	},
	closeDlg:function(){
		$('divwitness').style.display = "none";
	}
}

var EditDlg = {
	type : 0,
	post_id : 0,
	showDlg:function(type, post_id) {	
	  var isShow = false;
		if (! $('diveditdlg')) {
			var tempDiv   =   document.createElement('div'); 
			tempDiv.id = "diveditdlg";
			tempDiv.style.cssText = "position:absolute; left:0px; top:0px; background-color:#ECE9D8;width:380px;height:150px;";
			document.body.appendChild(tempDiv);   
			tempDiv.innerHTML='<div id="DlgTitle2" class="DlgTitle"><h1>修改物件</h1><div class="DlgClose" onclick="EditDlg.closeDlg();" title="關閉"></div></div><iframe id="ifeditdlg" name="ifeditdlg" width="378px" frameborder="0" scrolling="no" height="150" src="index.php?module=userCenter&action=editDlg" style="border:1px solid #FF9900;"></iframe>';
			Drag.init($('DlgTitle2'), $('diveditdlg'));	
		} else {
			isShow = true;
		}
		this.setPosition($('diveditdlg'));
		$('diveditdlg').style.display = '';
		this.type = type;
		this.post_id = post_id;
	},setPosition:function(obj) {		
		if (self.innerHeight) {	// all except Explorer
			windowHeight = self.innerHeight;
		}	else {
			windowHeight = document.documentElement.clientHeight;
		}
		obj.style.left = (document.documentElement.clientWidth - parseInt(obj.style.width))/2 + 'px';
		obj.style.top = document.documentElement.scrollTop + (windowHeight - parseInt(obj.style.height))/2 + 'px';
	}, closeDlg:function(){
		$('diveditdlg').style.display = "none";
	}
}

//刊登升級VIP方案
var Dlgwidget = {
	type : 0,
	post_id : 0,
	showDlg:function(type, post_id, isvip) {
	    var isShow = false;
		if (! $('Dlg_box')) {
			var tempDiv   =   document.createElement('div'); 
			tempDiv.id = "Dlg_box";
			tempDiv.style.cssText = "position:absolute; left:0px; top:0px; background-color:#f0faff;width:555px;height:276px;";
			document.body.appendChild(tempDiv);   
			tempDiv.innerHTML='<div id="DlgTitle" class="DlgTitle Dlgwidget" ><h1>升級至VIP方案</h1><div class="DlgClose" onclick="Dlgwidget.closeDlg();" title="關閉"></div></div><iframe id="dlgframe" name="dlgframe" width="553px" frameborder="0" scrolling="no" height="276" src="index.php?module=userCenter&action=vipmode" style="border:2px solid #b3d1fe; filter:chroma(color=#FFFFFF);"></iframe>';
			Drag.init($('DlgTitle'), $('Dlg_box'));	
		} else {
			isShow = true;
		}
		this.setPosition($('Dlg_box'));
		$('Dlg_box').style.display = '';
		this.type = type;
		this.post_id = post_id;
		if (isShow) {
			//$('dlgframe').contentWindow.setInfo();
		}
	},
	setPosition:function(obj) {		
		if (self.innerHeight) {	// all except Explorer
			windowHeight = self.innerHeight;
		}	else {
			windowHeight = document.documentElement.clientHeight;
		}
		obj.style.left = (document.documentElement.clientWidth - parseInt(obj.style.width))/2 + 'px';
		obj.style.top = document.documentElement.scrollTop + (windowHeight - parseInt(obj.style.height))/2 + 'px';
	},
	closeDlg:function(){
		$('Dlg_box').style.display = "none";
		document.body.removeChild($('Dlg_box'));
	}
}


//續刊操作
var Dlgwidget_repost = {
	type : 0,
	post_id : 0,
    moneytype : 1,
	showDlg:function(type, post_id, repost, moneytype) {
	    var isShow = false;
		if (! $('Dlg_box')) {
			var tempDiv   =   document.createElement('div'); 
			tempDiv.id = "Dlg_box";
			tempDiv.style.cssText = "position:absolute; left:0px; top:0px; background-color:#f0faff;width:555px;height:276px;";
			document.body.appendChild(tempDiv);   
			tempDiv.innerHTML='<div id="DlgTitle" class="DlgTitle Dlgwidget"><h1>續刊房屋廣告</h1><div class="DlgClose" onclick="Dlgwidget.closeDlg();" title="關閉"></div></div><iframe id="dlgframe" name="dlgframe" width="553px" frameborder="0" scrolling="no" height="276" src="index.php?module=userCenter&action=repost" style="border:2px solid #b3d1fe;filter:chroma(color=#FFFFFF);"></iframe>';
			Drag.init($('DlgTitle'), $('Dlg_box'));	
		} else {
			isShow = true;
		}
		this.setPosition($('Dlg_box'));
		$('Dlg_box').style.display = '';
		this.type = type;
		this.post_id = post_id;
        this.moneytype = moneytype;
		if (isShow) {
			//$('dlgframe').contentWindow.setInfo();
		}
	},
	setPosition:function(obj) {		
		if (self.innerHeight) {	// all except Explorer
			windowHeight = self.innerHeight;
		}	else {
			windowHeight = document.documentElement.clientHeight;
		}
		obj.style.left = (document.documentElement.clientWidth - parseInt(obj.style.width))/2 + 'px';
		obj.style.top = document.documentElement.scrollTop + (windowHeight - parseInt(obj.style.height))/2 + 'px';
	},
	closeDlg:function(){
		$('Dlg_box').style.display = "none";
		document.body.removeChild($('Dlg_box'));
	}
}



//續刊操作
var Dlgwidget_repost_service = {
	type : 0,
	post_id : 0,
	showDlg:function(type, post_id, repost) {
	    var isShow = false;
		if (! $('Dlg_box')) {
			var tempDiv   =   document.createElement('div'); 
			tempDiv.id = "Dlg_box";
			tempDiv.style.cssText = "position:absolute; left:0px; top:0px; background-color:#f0faff;width:555px;height:276px;";
			document.body.appendChild(tempDiv);   
			tempDiv.innerHTML='<div id="DlgTitle" class="DlgTitle Dlgwidget"><h1>續刊廠商廣告</h1><div class="DlgClose" onclick="Dlgwidget.closeDlg();" title="關閉"></div></div><iframe id="dlgframe" name="dlgframe" width="553px" frameborder="0" scrolling="no" height="276" src="index.php?module=service&action=repost" style="border:2px solid #b3d1fe;"></iframe>';
			Drag.init($('DlgTitle'), $('Dlg_box'));	
		} else {
			isShow = true;
		}
		this.setPosition($('Dlg_box'));
		$('Dlg_box').style.display = '';
		this.type = type;
		this.post_id = post_id;
		if (isShow) {
			//$('dlgframe').contentWindow.setInfo();
		}
	},
	setPosition:function(obj) {		
		if (self.innerHeight) {	// all except Explorer
			windowHeight = self.innerHeight;
		}	else {
			windowHeight = document.documentElement.clientHeight;
		}
		obj.style.left = (document.documentElement.clientWidth - parseInt(obj.style.width))/2 + 'px';
		obj.style.top = document.documentElement.scrollTop + (windowHeight - parseInt(obj.style.height))/2 + 'px';
	},
	closeDlg:function(){
		$('Dlg_box').style.display = "none";
		document.body.removeChild($('Dlg_box'));
	}
}



//續刊操作
var Dlgwidget_calResult = {
	first : 0,
	price : 0,
	showDlg:function(first, price) {
	    var isShow = false;
		if (! $('Dlg_box')) {
			var tempDiv   =   document.createElement('div'); 
			tempDiv.id = "Dlg_box";
			tempDiv.style.cssText = "position:absolute; left:0px; top:0px; background-color:#ECE9D8;width:450px;height:250px;";
			document.body.appendChild(tempDiv);   
			tempDiv.innerHTML='<div id="DlgTitle" class="DlgTitle"><h1>房貸試算</h1><div class="DlgClose" onclick="Dlgwidget.closeDlg();" title="關閉"></div></div><iframe id="dlgframe" name="dlgframe" width="450px" frameborder="0" scrolling="no" height="250" src="index.php?module=house&action=calResult" style="border:1px solid #858585;"></iframe>';
			Drag.init($('DlgTitle'), $('Dlg_box'));	
		} else {
			isShow = true;
		}
		this.setPosition($('Dlg_box'));
		$('Dlg_box').style.display = '';
		this.first = first;
		this.price = price;
		if (isShow) {
			//$('dlgframe').contentWindow.setInfo();
		}
	},
	setPosition:function(obj) {		
		if (self.innerHeight) {	// all except Explorer
			windowHeight = self.innerHeight;
		}	else {
			windowHeight = document.documentElement.clientHeight;
		}
		obj.style.left = (document.documentElement.clientWidth - parseInt(obj.style.width))/2 + 'px';
		obj.style.top = document.documentElement.scrollTop + (windowHeight - parseInt(obj.style.height))/2 + 'px';
	},
	closeDlg:function(){
		$('Dlg_box').style.display = "none";
		document.body.removeChild($('Dlg_box'));
	}
}


// 關閉彈出?
function dlgclose(msg, closewin)
{
	if(typeof(msg)=='undefined'){
		closewin =0;		
	}
	if(typeof(closwin)=='undefined'){
		closewin =1;		
	}
	if(closewin){
		Dlgwidget.closeDlg();
	}
	if(msg){
		alert(msg);
	}
}

//開啟物件
var Dlgopenhouse = {
	type : 0,
	post_id : 0,
	isvip : '',
	showDlg:function(type, post_id, isvip) {
		//if (false == window.confirm("請選擇物件的刊登方案?)) return false;
	    var isShow = false;
		if (! $('Dlg_box')) {
			var tempDiv   =   document.createElement('div'); 
			tempDiv.id = "Dlg_box";
			tempDiv.style.cssText = "position:absolute; left:0px; top:0px; background-color:#f0faff;width:555px;height:276px;";
			document.body.appendChild(tempDiv);   
			tempDiv.innerHTML='<div id="DlgTitle" class="DlgTitle Dlgwidget"><h1>開啟房屋廣告</h1><div class="DlgClose" onclick="Dlgopenhouse.closeDlg();" title="關閉"></div></div><iframe id="dlgframe" name="dlgframe" width="553px" frameborder="0" scrolling="no" height="276" src="index.php?module=userCenter&action=openhouse" style="border:2px solid #b3d1fe;filter:chroma(color=#FFFFFF);"></iframe>';
			Drag.init($('DlgTitle'), $('Dlg_box'));	
		} else {
			isShow = true;
		}
		this.setPosition($('Dlg_box'));
		$('Dlg_box').style.display = '';
		this.type = type;
		this.post_id = post_id;
		this.isvip = isvip;
		if (isShow) {
			//$('dlgframe').contentWindow.setInfo();
		}
	},
	setPosition:function(obj) {		
		if (self.innerHeight) {	// all except Explorer
			windowHeight = self.innerHeight;
		}	else {
			windowHeight = document.documentElement.clientHeight;
		}
		obj.style.left = (document.documentElement.clientWidth - parseInt(obj.style.width))/2 + 'px';
		obj.style.top = document.documentElement.scrollTop + (windowHeight - parseInt(obj.style.height))/2 + 'px';
	},
	closeDlg:function(){
		$('Dlg_box').style.display = "none";
		document.body.removeChild($('Dlg_box'));
	}
}
//保存格局?
function saveDrawer(id)
{
	var url = "./index.php?module=userCenter&action=saveMyDrawer&id="+id+"&note="+$('drawerNote'+id).value+"";
	Http_Get_Request(url, reSaveDrawer);
}
function reSaveDrawer(val)
{
	if('success' == val){
		alert("保存成功");
	}else{
		alert(val);
	}
}

/*
//收藏彈框
var Dlgwidget_popup = {
	showDlg:function(result) {
	    var isShow = false;
		if (! $('Dlg_box')) {
			var tempDiv   =   document.createElement('div'); 
			tempDiv.id = "Dlg_box";
			tempDiv.style.cssText = "position:absolute; left:0px; top:0px; background-color:#f0faff;width:485px;height:200px;";
			document.body.appendChild(tempDiv);   
			tempDiv.innerHTML='<div id="DlgTitle" class="DlgTitle Dlgwidget_popup"><h1>收藏房屋資訊</h1><div class="DlgClose" onclick="Dlgwidget.closeDlg();" title="關閉"></div></div><iframe id="dlgframe" name="dlgframe" width="483px" frameborder="0" scrolling="no" height="200" src="index.php?module=favorite&action=favtip&result&result=' + myencode(result) + '" style="border:2px solid #b3d1fe;filter:chroma(color=#FFFFFF);"></iframe>';
			Drag.init($('DlgTitle'), $('Dlg_box'));	
		} else {
			isShow = true;
		}
		this.setPosition($('Dlg_box'));
		$('Dlg_box').style.display = '';
		if (isShow) {
			//$('dlgframe').contentWindow.setInfo();
		}
	},
	setPosition:function(obj) {		
		if (self.innerHeight) {	// all except Explorer
			windowHeight = self.innerHeight;
		}	else {
			windowHeight = document.documentElement.clientHeight;
		}
		obj.style.left = (document.documentElement.clientWidth - parseInt(obj.style.width))/2 + 'px';
		obj.style.top = document.documentElement.scrollTop + (windowHeight - parseInt(obj.style.height))/2 + 'px';
	},
	closeDlg:function(){
		$('Dlg_box').style.display = "none";
		document.body.removeChild($('Dlg_box'));
	}
}
*/

//收藏彈框
var Dlgwidget_popup = {
	showDlg:function(result) {
	    var isShow = false;
		if (! $('Dlg_box')) {
			var tempDiv   =   document.createElement('div'); 
			tempDiv.id = "Dlg_box";
            var param = '房屋';
            var paramArr = result.split('|*|');
            if (5 == paramArr[0]){//服務廠商
                param = '廠商';
                var len = paramArr.length;
                var result = '';
                for (i=1; i<len; i++ ){
                    result += paramArr[i]+'|*|';
                }
                result += paramArr[0];
            }
            
			tempDiv.style.cssText = "position:absolute; left:0px; top:0px; background-color:#f0faff;width:485px;height:200px;";
			document.body.appendChild(tempDiv);   
			tempDiv.innerHTML='<div id="DlgTitle" class="DlgTitle Dlgwidget_popup"><h1>收藏'+param+'資訊</h1><div class="DlgClose" onclick="Dlgwidget.closeDlg();" title="關閉"></div></div><iframe id="dlgframe" name="dlgframe" width="483px" frameborder="0" scrolling="no" height="200" src="index.php?module=favorite&action=favtip&result&result=' + myencode(result) + '" style="border:2px solid #b3d1fe;filter:chroma(color=#FFFFFF);"></iframe>';
			Drag.init($('DlgTitle'), $('Dlg_box'));	
		} else {
			isShow = true;
		}
		this.setPosition($('Dlg_box'));
		$('Dlg_box').style.display = '';
		if (isShow) {
			//$('dlgframe').contentWindow.setInfo();
		}
	},
	setPosition:function(obj) {		
		if (self.innerHeight) {	// all except Explorer
			windowHeight = self.innerHeight;
		}	else {
			windowHeight = document.documentElement.clientHeight;
		}
		obj.style.left = (document.documentElement.clientWidth - parseInt(obj.style.width))/2 + 'px';
		obj.style.top = document.documentElement.scrollTop + (windowHeight - parseInt(obj.style.height))/2 + 'px';
	},
	closeDlg:function(){
		$('Dlg_box').style.display = "none";
		document.body.removeChild($('Dlg_box'));
	}
}

//搜尋記錄保存
var Dlgwidget_updatesearch = {
	save_id:0,
	showDlg:function(save_id) {
	    var isShow = false;
		this.save_id = save_id;
		if (! $('Dlg_box')) {
			var tempDiv   =   document.createElement('div'); 
			tempDiv.id = "Dlg_box";
			tempDiv.style.cssText = "position:absolute; left:0px; top:0px; background-color:#f0faff;width:472px;height:260px;";
			document.body.appendChild(tempDiv);   
			tempDiv.innerHTML='<div id="DlgTitle" class="DlgTitle Dlgwidget_updatesearch" style="border-top:2px #b3d1fe solid;border-left:2px #b3d1fe solid;width:99%;"><h1>保存搜尋條件</h1><div class="DlgClose" onclick="Dlgwidget_updatesearch.closeDlg();" title="關閉"></div></div><iframe id="dlgframe" name="dlgframe" width="470px" frameborder="0" scrolling="no" height="257" src="index.php?module=house&action=savesearch&save_id=' + myencode(save_id) + '" style="border:2px solid #b3d1fe;filter:chroma(color=#FFFFFF);"></iframe>';
			Drag.init($('DlgTitle'), $('Dlg_box'));	
		} else {
			isShow = true;
		}
		this.setPosition($('Dlg_box'));
		$('Dlg_box').style.display = '';
		if (isShow) {
			//$('dlgframe').contentWindow.setInfo();
		}
	},
	setPosition:function(obj) {		
		if (self.innerHeight) {	// all except Explorer
			windowHeight = self.innerHeight;
		}	else {
			windowHeight = document.documentElement.clientHeight;
		}
		obj.style.left = (document.documentElement.clientWidth - parseInt(obj.style.width))/2 + 'px';
		obj.style.top = document.documentElement.scrollTop + (windowHeight - parseInt(obj.style.height))/2 + 'px';
	},
	closeDlg:function(){
		$('Dlg_box').style.display = "none";
		document.body.removeChild($('Dlg_box'));
	}
}
//會員暫時關閉
var Dlgcloseware = {
	//type : 0,
	//post_id : 0,
	showDlg:function(valStr) {
	    var isShow = false;
		if (! $('Dlg_box')) {
			var tempDiv   =   document.createElement('div'); 
			tempDiv.id = "Dlg_box";
			//tempDiv.style.cssText = "position:absolute; left:0px; top:0px; background-color:#f0faff;width:550px;*width:540px;_width:550px;height:206px;";
            tempDiv.style.cssText = "z-index:99999;position:absolute; left:0px; top:0px; background-color:#ffffff;width:550px!important;width:550px;height:206px;";
			document.body.appendChild(tempDiv);   
			tempDiv.innerHTML='<div id="DlgTitle" class="DlgTitle Dlgwidget dealTitle" style="width:550px!important;*width:546px;margin-bottom:0;"><h1 style="font-size:14pt;color:#3333330;top:4px;margin-left:9px;">暫時關閉</h1><div class="DlgClose" onclick="Dlgcloseware.closeDlg();" title="關閉"></div></div><iframe id="dlgframe" name="dlgframe" frameborder="0" scrolling="no" src="index.php?module=userCenter&action=userCloseWare&wareStr='+valStr+'" style="border:2px solid #b3d1fe; filter:chroma(color=#FFFFFF);width:550px;_width:546px;height:206px;"></iframe>';
			Drag.init($('DlgTitle'), $('Dlg_box'));	
		} else {
			isShow = true;
		}
		this.setPosition($('Dlg_box'));
		$('Dlg_box').style.display = '';
		//this.type = type;
		//this.post_id = post_id;
		if (isShow) {
			//$('dlgframe').contentWindow.setInfo();
		}
	},
	setPosition:function(obj) {		
		if (self.innerHeight) {	// all except Explorer
			windowHeight = self.innerHeight;
		}	else {
			windowHeight = document.documentElement.clientHeight;
		}
		obj.style.left = (document.documentElement.clientWidth - parseInt(obj.style.width))/2 + 'px';
		obj.style.top = document.documentElement.scrollTop + (windowHeight - parseInt(obj.style.height))/2 + 'px';
	},
	closeDlg:function(){
		$('Dlg_box').style.display = "none";
		document.body.removeChild($('Dlg_box'));
        
	}
}
//關閉物件跳轉
function closeWareJump(msg){
    //Dlgcloseware.closeDlg();
    alert(msg);
    window.location="./index.php?module=userCenter&action=expireWare&list=RS";
}


function ctlDlg(e)
{
	var curDisplay = $('hookDlgClsAdd').style.display;
	var fshow = 'none';
	if ('none' == curDisplay) {
		fshow = '';
	}
	e = Drag.fixE(e);
	var ey    = e.clientY;
	var ex    = e.clientX;
	if (ex + 286 > 620) {
		ex = 620  - 278;
	}		 
	$('hookDlgClsAdd').style.left = ex;
	$('hookDlgClsAdd').style.top = ey + 6;
	$('hookDlgClsAdd').style.display = fshow;		 
	if ('' == fshow) {
		$('txtNewClass').value = '';
		$('txtNewClass').focus();
	}		 
}

//搜尋記錄保存
var Dlgwidget_searchCookie = {
	save_id:0,
	showDlg:function(type,e) {
	    var isShow = false;
		this.type = type;
		if (! $('Dlg_box')) {
			var tempDiv   =   document.createElement('div'); 
			tempDiv.id = "Dlg_box";
			tempDiv.style.cssText = "position:absolute; left:0px; top:0px; background-color:#f0faff;width:740px;height:260px;z-index:99999";
			
			e = Drag.fixE(e);
			var ey    = e.clientY;
			var ex    = e.clientX;
			if (ex + 286 > 620) {
				//ex = 620  - 278;
			}
			if(is_ie){
				//is_ie
				ex = 354;
				ey = ey + 29;
			}else{
				//is_moz
				ex = $("searchCondition").offsetLeft;
				ey = $("searchCondition").offsetTop + $("searchCondition").offsetHeight ;
			}
			
			
			tempDiv.style.cssText = "position:absolute; left:" + ex +"px; top:" + ey +"px; background-color:#f0faff;width:750px;height:230px;z-index:99999";
			
			getSearchCookie("item_searchs");//getSearchCookie
			save_id_str = item_arr_search;
			document.body.appendChild(tempDiv);
			var moreSearch = "";
			if($("islogin").value){
				moreSearch = '<a href="index.php?module=userCenter&action=searchcondition">查看更多搜尋條件&gt;&gt;</a>';
			}			
			tempDiv.innerHTML='<div id="DlgTitle" class="DlgTitle Dlgwidget_searchCookie" style="cursor:default;"><h1 id="DlgTitle_h1">您最近的搜尋記錄'+ moreSearch +'</h1><div class="DlgClose" onclick="Dlgwidget_searchCookie.closeDlg();" title="關閉"></div></div><iframe id="dlgframe" name="dlgframe" width="740px" frameborder="0" scrolling="no" height="227" src="index.php?module=house&action=searchCookie&type='+ myencode(type) +'&save_id_str=' + myencode(save_id_str) + '" style="border:2px solid #b3d1fe;filter:chroma(color=#FFFFFF);"></iframe>';
			//Drag.init($('DlgTitle'), $('Dlg_box'));	
			var ifr = $("dlgframe");  
			ifr.src = 'index.php?module=house&action=searchCookie&type='+ myencode(type) +'&save_id_str=' + myencode(save_id_str);     
		} else {
			isShow = true;
		}
		//this.setPosition($('Dlg_box'));
		$('Dlg_box').style.display = '';
		if (isShow) {
			//$('dlgframe').contentWindow.setInfo();
		}
	},
	setPosition:function(obj) {		
		if (self.innerHeight) {	// all except Explorer
			windowHeight = self.innerHeight;
		}	else {
			windowHeight = document.documentElement.clientHeight;
		}
		obj.style.left = (document.documentElement.clientWidth - parseInt(obj.style.width))/2 + 'px';
		obj.style.top = document.documentElement.scrollTop + (windowHeight - parseInt(obj.style.height))/2 + 'px';
	},
	closeDlg:function(){
		$('Dlg_box').style.display = "none";
		document.body.removeChild($('Dlg_box'));
	}
}