/*
var divid = "eMeng1";

//window.onload = getMsg;
//window.onresize = resizeDiv;
//window.onerror = function(){}
//短信提示使用(asilas添加)
//var divTop,divLeft,divWidth,divHeight,docHeight,docWidth,objTimer,i = 0;
function getMsg()
{
    try
    {
        divTop = parseInt(document.getElementById(divid).style.top,10);
        divLeft = parseInt(document.getElementById(divid).style.left,10);
        divHeight = parseInt(document.getElementById(divid).offsetHeight,10);
        divWidth = parseInt(document.getElementById(divid).offsetWidth,10);
        docWidth = document.body.clientWidth;
        docHeight = document.body.clientHeight;
        document.getElementById(divid).style.top = parseInt(document.body.scrollTop,10) + docHeight + 10;// divHeight
        document.getElementById(divid).style.left = parseInt(document.body.scrollLeft,10) + docWidth - divWidth;
        document.getElementById(divid).style.visibility="visible";
        objTimer = window.setInterval("moveDiv()",10);

        setCookie("popup","yes");
    }

    catch(e)
    {
    }
}

function resizeDiv()
{
    i += 1;
    //if(i>300) closeDiv()    //客户想不用自动消失由用户来自己关闭所以屏蔽这句
    try
    {
        divHeight = parseInt(document.getElementById(divid).offsetHeight,10);
        divWidth = parseInt(document.getElementById(divid).offsetWidth,10);
        docWidth = document.body.clientWidth;
        docHeight = document.body.clientHeight;
        document.getElementById(divid).style.top = docHeight - divHeight + parseInt(document.body.scrollTop,10);
        document.getElementById(divid).style.left = docWidth - divWidth + parseInt(document.body.scrollLeft,10);
    }

    catch(e)
    {
    }
}

function moveDiv()
{
    try
    {
        if(parseInt(document.getElementById(divid).style.top,10) <= (docHeight - divHeight + parseInt(document.body.scrollTop,10)))
        {
            window.clearInterval(objTimer);
            objTimer = window.setInterval("resizeDiv()",1);
        }

        divTop = parseInt(document.getElementById(divid).style.top,10);
        document.getElementById(divid).style.top = divTop - 1;
    }
    catch(e){}
}
function closeDiv()
{
    document.getElementById('eMeng1').style.visibility='hidden';

    if(objTimer)
       window.clearInterval(objTimer);
}

// 保存 Cookie
function setCookie (name, value)
{
    var expires  = new Date();
    var month    = expires.getMonth();
    var day      = expires.getDate();
    var year     = expires.getFullYear();
    var pasttime = Date.UTC(year,month,day)+24*3600*1000;
    expires.setTime(pasttime);

    document.cookie = name + "=" + escape(value) + "; expires=" + expires.toGMTString() + "; path=/;";
}

// 获取 Cookie
function get_cookie(Name)
{
    var search = Name + "="
    var returnvalue = "";
    if (document.cookie.length > 0)
    {
        offset = document.cookie.indexOf(search);

        if (offset != -1)
        { // if cookie exists
            offset += search.length
            // set index of beginning of value
            end = document.cookie.indexOf(";", offset);
            // set index of end of cookie value
            if (end == -1)
                end = document.cookie.length;

            returnvalue=unescape(document.cookie.substring(offset, end))
        }
    }
    return returnvalue;
}

// 清除 Cookie
function delCookie ( name )
{
    var expireNow = new Date();
    document.cookie = name + "=" + "; expires=Thu, 01-Jan-70 00:00:01 GMT" + "; path=/;domain=.51edu.com";
}
*/
 function winopen()
 {
	 //if(get_cookie("popup") == "")
	 //{
     //window.open("http://www.51edu.com/page/mini/","miniwindows","height=430,width=598,top=400,left=400,status=no,toolbar=no,menubar=no,location=no");
     //setCookie("popup","kevinkong");
	 //}
 }
/*
 function getIEVersion()
 {
     if(navigator.userAgent.indexOf("MSIE")>0)
        return 1;
     else if(isFirefox=navigator.userAgent.indexOf("Firefox")>0)
        return 2;
     else
        return 0;
 }
*/
