vendredi 13 avril 2018

ASP.NET pattern in html

I have some page, where i want to enter values in pattern "text.text" (separator point required element), other values will not be adopted. I use pattern in cshtml page, but value entered both with "." without her. How correctly use a pattern?

<form asp-action="Create" asp-controller="Documents" method="post" enctype="multipart/form-data">
    <p>
        <label>DocumentName</label>
        <input name="DocumentName" class="form-control" pattern="[A-Za-zА-Яа-яЁё]\.[A-Za-zА-Яа-яЁё]" required />
    </p>

Aucun commentaire:

Enregistrer un commentaire