/^[A-Za-z0-9]+([-|_]?)*(\.[A-Za-z0-9]*)?@[A-Za-z0-9]+([-|_]?)*[A-Za-z0-9]+\.[A-Za-z]+(\.[A-Za-z]*)?/

解决方案 »

  1.   

    var re=/^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,3})+$/;
      

  2.   

    var re=/\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,3})+$/;
      

  3.   

    /\w+([-+.]\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*/
    试下这个
      

  4.   

    <html>
    <head>
    <script type="text/javascript">
    var email="@yahoo.com";
    myReg=/^[A-Za-z0-9]+([-|_]?)*(\.[A-Za-z0-9]*)?@[A-Za-z0-9]+([-|_]?)*[A-Za-z0-9]+\.[A-Za-z]+(\.[A-Za-z]*)?/
    if(email.match(myReg))
    {
        myStr=email.bold().fontcolor("red");
    }else
    {
        myStr=email.bold().fontcolor("green");
    }
    </script>
    </head>
    <body>
    <script type="text/javascript">
    document.write(myStr)
    </script>
    </body>
    </html>用这个自己检查吧。
      

  5.   

    /\w+([-+.]\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*/
    这段连!#¥%……&*()这种代码都会放过,不合适,所以才自己写
      

  6.   

    \w 只包括 [A-Za-z0-9_]
    参考链接 http://www.yesky.com/imagesnew/software/vbscript/html/jsgrpRegExpSyntax.htm