PHP code example of sgu-infocom-official / inputmask_v3.3.11
1. Go to this page and download the library: Download sgu-infocom-official/inputmask_v3.3.11 library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
sgu-infocom-official / inputmask_v3.3.11 example snippets
javascript
$(selector).inputmask({ mask: "9[-9999]", greedy: false });
javascript
$(selector).inputmask({ mask: function () { /* do stuff */ return ["[1-]AAA-999", "[1-]999-AAA"]; }});
javascript
Inputmask.extendAliases({
'numeric': {
allowPlus: false,
allowMinus: false
}
});
javascript
var unformattedDate = Inputmask.unmask("23/03/1973", { alias: "dd/mm/yyyy"}); //23031973
javascript
document.querySelector("#CellPhone").inputmask.option({
onBeforePaste: function (pastedValue, opts) {
return phoneNumOnPaste(pastedValue, opts);
}
});
javascript
var isValid = Inputmask.isValid("23/03/1973", { alias: "dd/mm/yyyy"});
javascript
$("#date").inputmask("date", { "clearIncomplete": true });
javascript
$("#date").inputmask({ alias: "date", "clearIncomplete": true });
javascript
$(selector).inputmask({
mask: '9999 9999 9999 9999',
placeholder: ' ',
showMaskOnHover: false,
showMaskOnFocus: false,
onBeforePaste: function (pastedValue, opts) {
var processedValue = pastedValue;
//do something with it
return processedValue;
}
});
javascript
$(document).ready(function(){
$(selector).inputmask('€ 999.999.999,99', { numericInput: true }); //123456 => € ___.__1.234,56
});
javascript
$(selector).inputmask({
regex: "[0-9]*",
isComplete: function(buffer, opts) {
return new RegExp(opts.regex).test(buffer.join(''));
}
});