//首页切换文字开始
function clean(j, k, n) {
    var i;
    for (i = j; i < k; i++) {
        divname = "key" + i;
        divname2 = "key" + n;
        tdname = "td" + i;
        tdname2 = "td" + n;
        tdname3 = "key" + j;
        eval(divname).style.display = 'none';
        eval(divname2).style.display = 'block';
        eval(tdname).className = 'gray';
        eval(tdname2).className = 'red';
    }
}
function Show(t) {
    x = event.clientX + document.body.scrollLeft; // get the mouse left position
    y = event.clientY + document.body.scrollTop + 20; // get the mouse top position 
    t.style.display = "block"; // display the pop-up
    t.style.left = x - 350; // set the pop-up's left
    t.style.top = y; // set the pop-up's top
}
function Hide(t) {
    t.style.display = "none"; // hide the pop-up
}
//首页切换文字结束

//首页广告开始
var NowFrame = 1;
var MaxFrame = 4;
var bStart = 0;
function fnToggle() {
    var next = NowFrame + 1;
    if (next == MaxFrame + 1) {
        NowFrame = MaxFrame; next = 1;
    }
    if (bStart == 0) {
        bStart = 1; setTimeout('fnToggle()', 1000);
        return;
    }
    else {
        oTransContainer.filters[0].Apply();
        document.images['oDIV' + next].style.display = "";
        document.images['oDIV' + NowFrame].style.display = "none";
        oTransContainer.filters[0].Play(duration = 2);
        if (NowFrame == MaxFrame) { NowFrame = 1; }
        else { NowFrame++; }
    }
    setTimeout('fnToggle()', 2000);
}
fnToggle();
//首页广告结束

//预置下拉广告开始 <body onload="showAds();">
var time = 500;
var h = 0;
function addCount() {
    if (time > 0) {
        time--;
        h = h + 5;
    }
    else {
        return;
    }
    if (h > 250)  //高度
    {
        return;
    }
    document.getElementById("ads").style.display = "";
    document.getElementById("ads").style.height = h + "px";
    setTimeout("addCount()", 30);
}

function showAds() {
    addCount();
    setTimeout("noneAds()", 3000); //停留时间自己适当调整
}

var T = 260;
var N = 250; //高度
function noneAds() {
    if (T > 0) {
        T--;
        N = N - 5;
    }
    else {
        return;
    }
    if (N < 0) {
        document.getElementById("ads").style.display = "none";
        return;
    }

    document.getElementById("ads").style.height = N + "px";
    setTimeout("noneAds()", 30);
}
//预置下拉广告结束

//判断用户名和密码是否为空 开始
function check_controlvalue(form_info, str)
//type:判断类型（empty是否为空；length长度是否过长；char是否为字符与数字的组合；num是否是数字）,form_info：表单与控件的对象名；   str：提示内容，str_len：字符串最大长度,   email：电子邮箱地址是否合法。   
{
    if (str == "") str = "请填写完整后再点击确定!";
    if (form_info.value == "") {
        alert(str);
        return false;
    }
    else return true; 
}
//判断用户名和密码是否为空 结束