• 邮件地址的问题


    什么样的邮件地址才是有效的?看了Wikipedia的解释着实让人吓了一跳(留存备考):

    Valid email addresses

    • niceandsimple@example.com
    • very.common@example.com
    • a.little.lengthy.but.fine@dept.example.com
    • disposable.style.email.with+symbol@example.com
    • user@[IPv6:2001:db8:1ff::a0b:dbd0]
    • "much.more unusual"@example.com
    • "very.unusual.@.unusual.com"@example.com
    • "very.(),:;<>[]\".VERY.\"very@\\ \"very\".unusual"@strange.example.com
    • 0@a
    • postbox@com (top-level domains are valid hostnames)
    • !#$%&'*+-/=?^_`{}|~@example.org
    • "()<>[]:,;@\\\"!#$%&'*+-/=?^_`{}| ~  ? ^_`{}|~.a"@example.org
    • ""@example.org

    Invalid email addresses

    • Abc.example.com (an @ character must separate the local and domain parts)
    • Abc.@example.com (character dot(.) is last in local part)
    • Abc..123@example.com (character dot(.) is double)
    • A@b@c@example.com (only one @ is allowed outside quotation marks)
    • a"b(c)d,e:f;g<h>i[j\k]l@example.com (none of the special characters in this local part is allowed outside quotation marks)
    • just"not"right@example.com (quoted strings must be dot separated, or the only element making up the local-part)
    • this is"not\allowed@example.com (spaces, quotes, and backslashes may only exist when within quoted strings and preceded by a backslash)
    • this\ still\"not\\allowed@example.com (even if escaped (preceded by a backslash), spaces, quotes, and backslashes must still be contained by quotes)
  • 相关阅读:
    获取字符串的MD5值
    将对象XML序列化为XML文件/反序列化XML文件为对象
    C#通过反射获得对象所有属性和值
    Jquery.Validate使用
    JS删除确认框
    生成验证码
    文件备份方法
    Log日志类
    Ext.NET 基础学习笔记08 (FormPanel)
    Tibco EMS Message trace
  • 原文地址:https://www.cnblogs.com/pinocchioatbeijing/p/2764933.html
Copyright © 2020-2023  润新知