Validate an International Bank Account Number (IBAN).
Option | Equivalent HTML attribute | Type | Description |
---|---|---|---|
message |
data-bv-iban-message |
String | The error message |
country |
data-bv-iban-country |
String | A ISO 3166 country code |
If the country
is not defined, it will be parsed from the IBAN number.
The validator supports the following countries (sorted by the country code in alphabetical order):
<form id="ibanForm" class="form-horizontal">
<div class="form-group">
<label class="col-lg-3 control-label">IBAN</label>
<div class="col-lg-5">
<input type="text" class="form-control" name="iban" />
</div>
</div>
</form>
<script>
$(document).ready(function() {
$('#ibanForm').bootstrapValidator({
feedbackIcons: {
valid: 'glyphicon glyphicon-ok',
invalid: 'glyphicon glyphicon-remove',
validating: 'glyphicon glyphicon-refresh'
},
fields: {
iban: {
validators: {
iban: {
message: 'The value is not valid IBAN'
}
}
}
}
});
});
</script>
Comments
If you want to report a bug, please submit the issue on Github. Do NOT post the issue here.
For a general question or feedback, use the form below.