// 防止被纳入框架
//if(top.location !== self.location){top.location=self.location;}
// ==================================================================================
//var MySiteDomain= document.location.href;
var design=" 此为官方站点:http://www.YonLi.cn";
var YL = new Object();
YL.FormBlink 	= false;	 //是否开启表单加亮功能
YL.ImgZoom 		= true;		 //false; //是否开启图像滚轮缩放功能
YL.TipsON 		= true;		 // 是否开启友情提示功能
YL.WinStatus 	= false;	 //是否开启状态栏提示功能
YL.Img			= true;		 //是否开启图像大小缩放.
// ******************************默认设置定义******************************
YL.TipsPop 				= null;
YL.TipsoffsetX 			= 10; // 提示框位于鼠标左侧或者右侧的距离；
YL.TipsoffsetY 			= 12; // 提示框位于鼠标下方的距离；
YL.TipsPopbg 			= "#FFFFFF"; // 提示框背景色
YL.TipsPopfg 			= "infotext"; // 提示框前景色
YL.TipsAlpha 			= 100; // 提示框透明度，100为不透明
YL.Tipsshadowcolor 		= "threedlightshadow"; // 提示框阴影颜色
YL.Tipsshadowdirection 	= 135; // 提示框阴影方向
//YL.TipsTitlebg 			= "#00780E";
YL.TipsTitlebg 			= "#EEEEEE" //"activecaption"; // 提示框标题文字背景
YL.TipsTitlefg 			= "#333333" //"captiontext"; // 提示框标题文字颜色
YL.TipsBorderColor 		= "#EEEEEE" //"activecaption"; // 提示框标题边框颜色
YL.TipsztColor			= "#0033CC"
YL.TipsBorder			= 1; // 提示框标题边框宽度
YL.TipsBaseWidth 		= 138; // 提示框最小宽度 注意这个值最好不要小于提示框的象素宽度
YL.TipsTitle 			= "提示"; // 提示框标题文字
YL.TipsSmallTitle 		= "51dg<sup>&reg;</sup> Message Hint";	// 提示框副标题文字 
YL.TipsTitleCt 			= " - " // 标题文字和副标题文字之间的连接符
YL.TipsStartmess		= "<FONT COLOR='" + YL.TipsztColor + "'>" //信息提示信息前边加的信息
YL.TipsEndmess			= "</FONT><BR /><Div ALIGN=RIGHT WIDTH=100% ><FONT COLOR=red>51dg</FONT>.Com</Div>" //信息提示信息后边加的信息
// ******************************默认设置定义******************************
//YL.StatusText = "永利工作室，欢迎您的到来！请记住：本站企业查询网址：http://www.Ybso.com";
//if(YL.WinStatus == true){window.status = YL.StatusText  + design;}
// ==================================================================================
var FormObj; UsedForm = "none";

document.write('<div id="YL___TipsLayer" style="display: none;position: absolute; z-index:10001"></div>');

function YL_Tips(){
	try{
		var o=event.srcElement;
		if(o.alt == null && o.title == null){return false;}
		if(o.alt != null && o.alt != ""){o.dypop = o.alt;o.alt = ""};
		if(o.title != null && o.title != ""){o.dypop = o.title;o.title = ""};
		YL.TipsPop = o.dypop;
		if(YL.TipsPop !=null && YL.TipsPop !="" && typeof(YL.TipsPop)!="undefined"){
			YL___TipsLayer.style.left=-1000;
			YL___TipsLayer.style.display='';
			var Msg = YL.TipsPop.replace(/\n/g,"<br>"); // 换行符
			Msg = Msg.replace(/\r/g,"<br>"); // 回车符
			Msg = Msg.replace(/\0x13/g,"<br>"); // 回车符
			Msg = YL.TipsStartmess + Msg + YL.TipsEndmess;
			//if(YL.TipsSmallTitle==""){YL.TipsTitleCt="";}
			if(YL.TipsSmallTitle == ""){YL.TipsSmallTitle = SystemVersion;}
			var content = '<table style="FILTER:alpha(opacity='+YL.TipsAlpha+') shadow(color='+YL.Tipsshadowcolor+',direction='+YL.Tipsshadowdirection+');" id=toolTipTalbe border=0><tr><td width="100%"><table border=0 cellspacing="'+YL.TipsBorder+'" cellpadding="2" style="width:100%;background-color:'+YL.TipsBorderColor+';">'+
			'<tr id=YL_TipsPoptop><th style="width:100%; font:bold 12px; text-indent: 0em; color:'+YL.TipsTitlefg+'; background-color:'+YL.TipsTitlebg+';"><b><p id=topleft align=left style="text-indent: 0em;">↖ '+YL.TipsTitle+YL.TipsTitleCt+YL.TipsSmallTitle+'</p><p id=topright align=right style="font:bold 12px; text-indent: 0em;display:none">'+YL.TipsSmallTitle+YL.TipsTitleCt+YL.TipsTitle+' ↗</font></b></th></tr>'+
			'<tr><td style="width:100%; font:12px; text-indent: 0em; background-color:'+YL.TipsPopbg+'; color:'+YL.TipsPopfg+'; padding-left:10px; padding-right:10px; padding-top: 4px; padding-bottom:4px; line-height:135%;font-family: Verdana, Arial, Helvetica, sans-serif, "宋体";">'+Msg+'</td></tr>'+
			'<tr id=YL_TipsPopbot style="display:none"><th style="width:100%; font:bold 12px; text-indent: 0em; color:'+YL.TipsTitlefg+';background-color:'+YL.TipsTitlebg+';"><b><p id=botleft align=left style="text-indent: 0em;">↙ '+YL.TipsTitle+YL.TipsTitleCt+YL.TipsSmallTitle+'</p><p id=botright align=right style="font:bold 12px; text-indent: 0em;display:none">'+YL.TipsSmallTitle+YL.TipsTitleCt+YL.TipsTitle+' ↘</font></b></th></tr>'+
			'</table></td></tr></table>';
			YL___TipsLayer.innerHTML = content;
			var toolTipwidth = Math.min(YL___TipsLayer.clientWidth, document.body.clientWidth/2.2);
			if(toolTipwidth<YL.TipsBaseWidth){toolTipwidth=YL.TipsBaseWidth;}
			toolTipTalbe.style.width=toolTipwidth;
			MoveToMouseLoc();
			return true;
		}else{
			YL___TipsLayer.innerHTML = "";
			YL___TipsLayer.style.display='none';
			return true;
		}
	}
	catch(e){};
}
function MoveToMouseLoc(){
	if(YL___TipsLayer.innerHTML==''){return true;}
	var MouseX=event.x;
	var MouseY=event.y;
	var popTopAdjust=0;
	//window.status="x:"+event.offsetX;
	//window.status+=" y:"+event.offsetY;
	var popHeight=YL___TipsLayer.clientHeight;
	var popWidth=YL___TipsLayer.clientWidth;
	if(MouseY+YL.TipsoffsetY+popHeight>document.body.clientHeight){
		popTopAdjust=-popHeight-YL.TipsoffsetY*1.5;
		YL_TipsPoptop.style.display="none";
		YL_TipsPopbot.style.display="";
	}else{
		popTopAdjust=0;
		YL_TipsPoptop.style.display="";
		YL_TipsPopbot.style.display="none";
	}
	if(MouseX+YL.TipsoffsetX+popWidth>document.body.clientWidth){
		popLeftAdjust=-popWidth-YL.TipsoffsetX*2;
		topleft.style.display="none";
		botleft.style.display="none";
		topright.style.display="";
		botright.style.display="";
	}else{
		popLeftAdjust=0;
		topleft.style.display="";
		botleft.style.display="";
		topright.style.display="none";
		botright.style.display="none";
	}
	YL___TipsLayer.style.left=MouseX+YL.TipsoffsetX+document.body.scrollLeft+popLeftAdjust;
	YL___TipsLayer.style.top=MouseY+YL.TipsoffsetY+document.body.scrollTop+popTopAdjust;
	return true;
}

if(YL.TipsON == true){
	document.onmousemove= YL_Tips;
}

// ---------------------------------------------------------------------------------
//图片缩放
function bbimg(o){
	if (YL.img==true)
	{
		var zoom=parseInt(o.style.zoom, 10)||100;zoom+=event.wheelDelta/12;if (zoom>0) o.style.zoom=zoom+'%';
		return false;
	}

}
// ---------------------------------------------------------------------------------
// 修改编辑栏高度
function obj_Size(num,objname)
{
	var obj=document.getElementById(objname)
	if (parseInt(obj.rows)+num>=3) {
		obj.rows = parseInt(obj.rows) + num;	
	}
	if (num>0)
	{
		obj.width="90%";
	}
}
// ---------------------------------------------------------------------------------
// 设置文章内容的颜色、大小、字体
function fontZoom(obj,size)
{
	document.getElementById(obj).style.fontSize=size+'px';
}
function fontColor(Color)
{
	document.getElementById(obj).style.color=Color;
}
function fontFamily(Family)
{
	document.getElementById(obj).style.fontFamily=Family;
}

var iXuEr = new Object();
//-----------------------------------------------------------------------------------
iXuEr.menuOffX = 0; // 菜单距连接文字最左端距离
iXuEr.menuOffY = 20; // 菜单距连接文字顶端距离
iXuEr.GetCodeSrc = ""; // 请勿更改
//-----------------------------------------------------------------------------------
// 状态栏提示文字：
//window.status = "如果您喜欢本站，请将本站推荐给您的朋友！本站访问地址：http://txt.51dg.com/";
//-----------------------------------------------------------------------------------
// Pop-it menu- (C) Dynamic Drive (www.dynamicdrive.com)
// This notice MUST stay intact for legal use
// Visit http://www.dynamicdrive.com/ for full source code
//-----------------------------------------------------------------------------------
var ie4 = document.all && navigator.userAgent.indexOf("Opera") == -1;
var ie5 = document.all && !window.opera;
var ns4 = document.layers;
var ns6 = document.getElementById && !document.all;
var vBobjects = new Array(), source_el, menuobj, delayhide;
document.write("<div id=\"PopMenu\" onmouseover=\"clearhidemenu();\" onmouseout=\"dynamichide(event);\"></div>");
function MM_findObj(n, d) {
	var p, i, x;
	if (!d) {
		d = document;
	}
	if ((p = n.indexOf("?")) > 0 && parent.frames.length) {
		d = parent.frames[n.substring(p + 1)].document;
		n = n.substring(0, p);
	}
	if (!(x = d[n]) && d.all) {
		x = d.all[n];
	}
	for (i = 0; !x && i < d.forms.length; i ++ ) {
		x = d.forms[i][n];
	}
	for (i = 0; !x && d.layers && i < d.layers.length; i ++ ) {
		x = MM_findObj(n, d.layers[i].document);
	}
	if (!x && d.getElementById) {
		x = d.getElementById(n);
	}
	return x;
}
function fetch_object(idname, forcefetch) {
	if (typeof (vBobjects[idname]) == "undefined") {
		vBobjects[idname] = MM_findObj(idname);
	}
	return vBobjects[idname];
}
function ShowMenu(e, vmenu, vmenuobj, mod) {
	clearhidemenu();
	var which = vmenu;
	if (vmenuobj) {
		var MenuObj = fetch_object(vmenuobj);
		if (MenuObj) {
			which = MenuObj.innerHTML;
		}
	}
	if (!which) {
		return;
	}
	which = "<div class=\"MenuSkin\"><div class=\"MenuBody\">" + which + "</div></div>";
	menuobj = document.getElementById("PopMenu");
	menuobj.thestyle = menuobj.style;
	menuobj.innerHTML = which;
	menuobj.contentwidth = menuobj.offsetWidth;
	eventX = e.clientX;
	eventY = e.clientY;
	var rightedge = document.body.clientWidth - eventX, bottomedge = document.body.clientHeight - eventY, getlength;
	if (rightedge < menuobj.contentwidth) {
		getlength = ie4 ? document.body.scrollLeft + eventX - menuobj.contentwidth + iXuEr.menuOffX : ns6 ? window.pageXOffset + eventX - menuobj.contentwidth : eventX - menuobj.contentwidth;
	} else {
		getlength = ie4 ? ie_x(event.srcElement) + iXuEr.menuOffX : ns6 ? window.pageXOffset + eventX : eventX;
	}
	menuobj.thestyle.left = getlength + "px";
	if (bottomedge < menuobj.contentheight && mod != 0) {
		getlength = ie4 ? document.body.scrollTop + eventY - menuobj.contentheight-event.offsetY + iXuEr.menuOffY - 23 : ns6 ? window.pageYOffset + eventY - menuobj.contentheight - 10 : eventY - menuobj.contentheight;
	} else {
		getlength = ie4 ? ie_y(event.srcElement) + iXuEr.menuOffY : ns6 ? window.pageYOffset + eventY + 10 : eventY;
	}
	menuobj.thestyle.top = getlength + "px";
	menuobj.thestyle.visibility = "visible";
}
function ie_y(e) {
	var t = e.offsetTop;
	while (e = e.offsetParent) {
		t  += e.offsetTop;
	}
	return t;
}
function ie_x(e) {
	var l = e.offsetLeft;
	while (e = e.offsetParent) {
		l  += e.offsetLeft;
	}
	return l;
}
function dynamichide(e) {
	if (ie5 && !menuobj.contains(e.toElement)) {
		hidemenu();
	} else if (ns6 && e.currentTarget != e.relatedTarget && !contains_ns6(e.currentTarget, e.relatedTarget)) {
		hidemenu();
	}
}
function hidemenu() {
	if (window.menuobj) {
		menuobj.thestyle.visibility = "hidden";
	}
}
function contains_ns6(a, b) {
	while (b.parentNode) {
		if ((b = b.parentNode) == a) {
			return true;
		}
	}
	return false;
}
function delayhidemenu() {
	delayhide = setTimeout("hidemenu()", 300);
}
function clearhidemenu() {
	try {
		window.clearTimeout(delayhide);
	} catch (e) {
	}
}
document.onclick = hidemenu;
//-----------------------------------------------------------------------------------
// 生成弹出窗口
function WinPop(url, NewWindowName, width, height, top, left, scrollbars, f){
	window.open(url, NewWindowName, 'width=' + width + ', height=' + height + ', top=' + top + ', left=' + left + ', toolbar=no, menubar=no, scrollbars=' + scrollbars + ', resizable=yes, location=no, status=no') 
	// 当f值不为0时，自动将窗口置后
	if(f!=0){window.focus();}
}
// 生成模式对话框
function DialogM(url, vArguments, width, height, scrollbars){
	window.showModalDialog(url, vArguments, "dialogWidth:" + width + "px; dialogHeight:" + height + "px; scroll:" + scrollbars + "; resizable:yes; location:no; status:no;") 
}
// 生成非模式对话框
function DialogL(url, vArguments, width, height, top, left, scrollbars){
	window.showModelessDialog(url, vArguments, "dialogWidth:" + width + "px; dialogHeight:" + height + "px; scroll:" + scrollbars + "; resizable:yes; location:no; status:no;") 
}
function ReLoadGetCode(){
	var GetCode = document.getElementById("GetCode");
	if(iXuEr.GetCodeSrc == ""){iXuEr.GetCodeSrc = GetCode.src;}
	GetCode.src = iXuEr.GetCodeSrc + "?t=" + Math.random();
}
//-----------------------------------------------------------------------------------
// 对链接开新窗口符合Web标准的补充脚本
// 将原来的 target="_blank" 修改为：rel="external"
// Guidy 2005-12-03
//-----------------------------------------------------------------------------------
function externalLinks(){
	if (!document.getElementsByTagName){return};
	var anchors = document.getElementsByTagName("a");
	for (var i=0; i<anchors.length; i++) {
		var anchor = anchors[i];
		if (anchor.getAttribute("href") && anchor.getAttribute("rel") == "external"){
			anchor.target = "_blank";
		}
	}
}
window.onload = externalLinks;
//-----------------------------------------------------------------------------------
// 输出一个Iframe
// Guidy 2005-12-31
//-----------------------------------------------------------------------------------
function drawIframe(p_Src, p_id, p_width, p_height, p_border){
		document.write("<iframe src=\"" + p_Src + "\" id=\"" + p_id + "\" style=\"height:" + p_height + "px; width:" + p_width + "px; border:" + p_border + "px solid #000000;\">您的浏览器不支持框架页</iframe>");	
}

