From the documentation http://1000hz.github.io/bootstrap-validator/:
Add custom validators to be run. Validators should be functions that receive the
You need to call your plugin manually, as custom options will not work with data-attributes:
custom
$().validator({ custom: { 'odd': function($el) { return Boolean($el.val() % 2);} } })
then use it like this:
Don't forget to add error messages, see code