Version 0.5.2

Released 25 September 2014

New features

  • Add verbose option
  • Add blank validator
  • Add init and destroy methods to validator
  • Add Venezuelan VAT number (RIF) validator
  • Add China phone number validator
  • Add Venezuela phone number validator
  • Add Romania phone number validator
  • Add Romania postal code validator
  • Add Denmark phone number validator
  • Add Thailand phone number and ID validator
  • Add Chinese citizen ID validator>
  • Add Russia phone number validator
  • Add Russian postal code validator
  • Add Czech and Slovakia phone number and postal code validators

Changes

  • Change the default type of remote validator to GET

Improvements

  • Add delay option to the remote validator
  • The different validator allows more than a 2-way comparison
  • The container option can be defined by a callback
  • Use CSS classes instead of inline styling to fix icons with input-group
  • The stringLength validator supports HTML 5 minlength attribute
  • The emailAddress validator accepts multiple email addresses
  • Reuse data returned by callback, remote, custom validators
  • The uri validator adds support for custom protocol
  • Support VAT number without prefixing by country code
  • Support latest Bootstrap when using tooltip/popover to show the message
  • Improve behaviour of the different validator
  • Add "BootstrapValidator's JavaScript requires jQuery" warning
  • Add minSize option for the file validator
  • Add phone number validator test suite

Bug fixes

  • Tabs get red even form is valid
  • Fix the emailAddress issue which email@server is not valid email address
  • Keep disabled validators VALID
  • Fix the issue when adding field which does not exist but is already set in "fields" option
  • Fix the issue when removing the radio or checkbox field
  • The form is still submitted when clicking on submit button which is set onclick="return false;"
  • Using notEmpty validator with type="number"
  • The tooltip/popover isn't shown if there is disabled validator. The tooltip/popover is shown automatically when the field gets the focus
  • Can't validate ipv4 and ipv6 at the same time. Add ip validator test suite
  • Fix Russian VAT number validator
  • The form won't be validated if the submit button contains a HTML tag

Upgrading from v0.5.x to v0.5.2

If you don't use the remote validator, just download v0.5.2 package and override the CSS/JS bundle.

Otherwise, please indicate the type option when using remote validator:


$(form).bootstrapValidator({
    fields: {
        username: {
            message: 'The username is not valid',
            validators: {
                // The validator will create an Ajax request
                // sending { username: 'its value' } to the back-end
                remote: {
                    message: 'The username is not available',
                    url: '/path/to/backend/',
                    type: 'GET'     // or 'POST'
                }
            }
        }
    }
});