    function CheckAll()
    {
        var b=false;
        
        b1=RegCheck("txtUserID","lblUserID");
        b2=RegCheck("txtUserPass","lblUserPass");
        b3=RegCheck("txtVerifyCode","lblVerifyCode");
        if(b1&&b2&&b3)
            b=true;
        return b;
    }
    
    function RegCheck(o1,o2)
    {
        if(o1=="txtUserID")
        {
            if(document.getElementById(o1).value=="")
            {
                document.getElementById(o2).innerHTML="<img src='../DotBBS_Net/images/reg-error.gif'width=18 height=18 align='absbottom'/> <font color='#ff0000'>帐号不能为空．</font>";
                return false;
            }
            if(document.getElementById(o1).value.length<2)
            {
                document.getElementById(o2).innerHTML="<img src='../DotBBS_Net/images/reg-error.gif'width=18 height=18 align='absbottom'/> <font color='#ff0000'>长度不能少于2字符．</font>";
                return false;
            }
            if(document.getElementById(o1).value.length>20)
            {
                document.getElementById(o2).innerHTML="<img src='../DotBBS_Net/images/reg-error.gif'width=18 height=18 align='absbottom'/> <font color='#ff0000'>长度不能超过给20字符．</font>";
                return false;
            }
            if(!IsCharNum(document.getElementById(o1).value))
            {
                document.getElementById(o2).innerHTML="<img src='../DotBBS_Net/images/reg-error.gif'width=18 height=18 align='absbottom'/> <font color='#ff0000'>格式不正确．</font>";
                return false;
            }
            
            document.getElementById(o2).innerHTML="";
            return true;
            
        }
        
        if(o1=="txtUserPass")
        {
            if(document.getElementById(o1).value=="")
            {
                document.getElementById(o2).innerHTML="<img src='../DotBBS_Net/images/reg-error.gif'width=18 height=18 align='absbottom'/> <font color='#ff0000'>密码不能为空．</font>";
                return false;
            }
            if(document.getElementById(o1).value.length<3)
            {
                document.getElementById(o2).innerHTML="<img src='../DotBBS_Net/images/reg-error.gif'width=18 height=18 align='absbottom'/> <font color='#ff0000'>长度不能少于3个字符．</font>";
                return false;
            }
            if(document.getElementById(o1).value.length>20)
            {
                document.getElementById(o2).innerHTML="<img src='../DotBBS_Net/images/reg-error.gif'width=18 height=18 align='absbottom'/> <font color='#ff0000'>长度不能超过给20字符．</font>";
                return false;
            }
            document.getElementById(o2).innerHTML="";
            return true;
            
        }  
        
        if(o1=="txtVerifyCode")
        {
            if(document.getElementById(o1).value=="")
            {
                document.getElementById(o2).innerHTML="<img src='../DotBBS_Net/images/reg-error.gif'width=18 height=18 align='absbottom'/> <font color='#ff0000'>验证码不能为空．</font>";
                return false;
            }
            document.getElementById(o2).innerHTML="";
            return true;
            
        }
        
    }
    
    
    function RegTipInfo(o1,msg)
    {
        document.getElementById(o1).innerHTML="<img src='../DotBBS_Net/images/reg-info.gif'width=18 height=18 align='absbottom'/> <font color='#ff6600'>"+msg+"</font>";
    }
   