Skip to content
This repository was archived by the owner on Apr 19, 2021. It is now read-only.
This repository was archived by the owner on Apr 19, 2021. It is now read-only.

电子邮件验证可以是中文吗? #19

@waleswood

Description

@waleswood

OSharp.Utility.Extensions命名空间下的

    /// <summary>
    /// 是否电子邮件
    /// </summary>
    public static bool IsEmail(this string value)
    {
        const string pattern = @"^[\w-]+(\.[\w-]+)*@[\w-]+(\.[\w-]+)+$";
        return value.IsMatch(pattern);
    }

没有对中文的非法判断。

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions