HTML and CSS Reference
or is available from the following CDN:
I have downloaded version 1.11.1 and added it to my scripts folder under the name
jquery.validate.js. I have also added it to the head section of the web page:
<link rel="stylesheet" type="text/css" href="styles/tasks.css"
Fortunately, jQuery validation relies on the same attributes as HTML5 where possible, so
the required attributes are valid for both HTML5 and jQuery validation.
jQuery validation contains a large number of built in validators, these allow you to express
• Validating a required field has a value.
• Validating a field contains a number.
• Validating the length of input data.
• Validating a number is in a range.
• Validating a field contains an email address.
• Validating a field contains a possibly valid credit card number.
In addition to these default validators; you can add your own validators.
In order to implement jQuery validation, we are first going to change the input field with
the name “task” to include a maximum length: