Skip to content

Instantly share code, notes, and snippets.

@zplume
Last active December 5, 2019 08:16
Show Gist options
  • Save zplume/932a5d049a6792f66024 to your computer and use it in GitHub Desktop.
Save zplume/932a5d049a6792f66024 to your computer and use it in GitHub Desktop.
HTML 5 / Kendo UI client-side validation for a password field with basic complexity requirements
<!--ASP.NET-->
<asp:Textbox runat="server" ClientIdMode="Static" type="password" id="PasswordTextbox" name="PasswordTextbox" pattern="^(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9]).{8,}$" validationmessage="Please enter a password which is at least 8 characters long and contains a lowercase character, an uppercase character and a number" required />
<!--HTML-->
<input type="password" id="PasswordTextbox" name="PasswordTextbox" pattern="^(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9]).{8,}$" validationmessage="Please enter a password which is at least 8 characters long and contains a lowercase character, an uppercase character and a number" required />
<!--Kendo UI Validator: http://demos.telerik.com/kendo-ui/validator/index -->
@sachinsharma9758
Copy link

it's not working

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment