Validate an US VIN (Vehicle Identification Number).
Option | Equivalent HTML attribute | Type | Description |
---|---|---|---|
message |
data-bv-vin-message |
String | The error message |
VIN | Result |
---|---|
1FAHP26W49G252740 | |
2FTRX07W53C371582 | |
WP0CA29863U153381 | |
JTMKF4DV5B5309254 |
http://randomvin.com helps you generate a random vin.
<form id="vinForm" class="form-horizontal">
<div class="form-group">
<label class="col-lg-3 control-label">VIN</label>
<div class="col-lg-5">
<input type="text" class="form-control" name="vin" />
</div>
</div>
</form>
<script>
$(document).ready(function() {
$('#vinForm').bootstrapValidator({
feedbackIcons: {
valid: 'glyphicon glyphicon-ok',
invalid: 'glyphicon glyphicon-remove',
validating: 'glyphicon glyphicon-refresh'
},
fields: {
vin: {
validators: {
vin: {
message: 'The VIN number is not valid'
}
}
}
}
});
});
</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.