function openPage(title ,iframeUrl,path) {
	var contextPath = "";
	if(path != null){
		contextPath = path;
	}
	var str ='<table id="detailContainer" width="100%" border="0" align="center" cellpadding="0" cellspacing="0"  style=" border:medium solid #eeeeee;">'
		+ '<tr>'
		+ '<td valign="top" style="border-top:1px #6D6E70 solid;border-right:1px #6D6E70 solid;border-bottom:1px #6D6E70 solid; background-color:#FFFFFF;filter:alpha(opacity=94); ">'
		+ '<table width="100%" border="0" cellspacing="0" cellpadding="0" background="'+contextPath+'images/nei_images/1x24.gif" style="margin:1px 1px 0px 1px;cursor:hand" id="tabDrawGift">'
		+ '<tr>'
		+ '<td height="25"><span style="color:#ffffff;font-weight:bold;">&nbsp;'+title+'</span></td>'
		+ '<td width="30" align="center"><a href="javascript:void%200;"><img onClick="top.document.getElementById(\'bgDiv\').style.display=\'none\';" src="'+contextPath+'images/nei_images/close.gif" width="16" height="16" border="0"></a></td></tr></table>'
		+ '<table width="100%" border="0" cellspacing="0" cellpadding="0"><tr><td>'
		+ '<div id="detailContent" style="word-break: break-all; overflow: auto; height:455px; width: 100%;">'
		+'<iframe name="drawGift" src="'+iframeUrl+'" width="100%" height="100%" frameborder="0"></iframe></div>'
		+ '</td></tr></table></td></tr>'
		+ '</table>'
	return str
}

function showDrawGift() {
	var contextPath = "";
	var iframeUrl = "promot/getAllGiftDraw.html?promotId=<ww:property value='promotId' />";
	var str ='<table id="detailContainer" width="100%" border="0" align="center" cellpadding="0" cellspacing="0">'
		+ '<tr>'
		+ '<td valign="top" style="border-top:1px #6D6E70 solid;border-right:1px #6D6E70 solid;border-bottom:1px #6D6E70 solid; background-color:#FFFFFF;filter:alpha(opacity=94); ">'
		+ '<table width="100%" border="0" cellspacing="0" cellpadding="0" background="'+contextPath+'images/nei_images/1x24.gif" style="margin:1px 1px 0px 1px;" id="tabDraw">'
		+ '<tr>'
		+ '<td height="25"><span style="color:#ffffff;font-weight:bold;">&nbsp;信息提醒</span></td>'
		+ '<td width="30" align="center"><a href="javascript:void%200;"><img onClick="top.document.getElementById(\'giftDiv\').style.display=\'none\';" src="'+contextPath+'images/nei_images/close.gif" width="16" height="16" border="0"></a></td></tr></table>'
		+ '<table width="100%" border="0" cellspacing="0" cellpadding="0" ><tr><td>'
		+ '<div id="drawGiftContent" name="drawGiftContent" style="word-break: break-all; overflow: auto; width: 100%;">'
		+'<iframe id="showDrawGift" name="showdrawGift" src="'+iframeUrl+'" width="100%" height="100%" frameborder="0"></iframe></div>'
		+ '</td></tr></table></td></tr>'
		+ '</table>'
	return str
}

function handleMouseMove() {
	var oEvent = EventUtil.getEvent();
	var oDiv = document.getElementById("bgDiv");
	oDiv.style.left = oEvent.clientX - iDiffX;
	oDiv.style.top = oEvent.clientY - iDiffY;
}
		   
function handleMouseDown() {
	var oEvent = EventUtil.getEvent();
	var oDiv = document.getElementById("bgDiv");
	iDiffX = oEvent.clientX - oDiv.offsetLeft;
	iDiffY = oEvent.clientY - oDiv.offsetTop;
	EventUtil.addEventHandler(document.body, "mousemove", handleMouseMove);
	EventUtil.addEventHandler(document.body, "mouseup", handleMouseUp);
}

function handleMouseUp() {
	var oEvent = EventUtil.getEvent();
	EventUtil.removeEventHandler(document.body, "mousemove", handleMouseMove);
	EventUtil.removeEventHandler(document.body, "mouseup", handleMouseUp);               
}

function showDiv() {
		var srcElement = window.srcElement || window.target;
		var msgw,msgh,bordercolor;
		msgw=300;//提示窗口的宽度
		msgh=200;//提示窗口的高度
		titleheight=25; //提示窗口标题高度
		bordercolor="#336699";//提示窗口的边框颜色
		titlecolor="#99CCFF";//提示窗口的标题颜色
		
		var sWidth,sHeight;
		//sWidth=document.body.offsetWidth;//浏览器工作区域内页面宽度
		//sHeight=screen.height;//屏幕高度（垂直分辨率）
		sWidth=312;
		//sHeight=250;
		
		//背景层（大小与窗口有效区域相同，即当弹出对话框时，背景显示为放射状透明灰色）
		
		var bgObj = top.document.getElementById("giftDiv");
		if(bgObj == null || bgObj  == undefined) {
			//创建一个div对象（背景层）
			bgObj = top.document.createElement("div");
		}
	
		bgObj.id = "giftDiv";
		bgObj.style.position="absolute";
		//bgObj.style.top="0px";
		bgObj.style.top="106px";
		bgObj.style.background="#3399ff";
		bgObj.style.filter="progid:DXImageTransform.Microsoft.Alpha(style=0,opacity=100,finishOpacity=75";
		bgObj.style.opacity="0.6";
		bgObj.style.right="18px";
		bgObj.style.width=sWidth + "px";
		//bgObj.style.height=sHeight + "px";
		bgObj.style.zIndex = "9";
		bgObj.style.display = "none";
		if(top.document.getElementById("giftDiv") == null) {
			top.document.body.appendChild(bgObj);
		} 
		bgObj.innerHTML = showDrawGift();
	}