samedi 16 juillet 2016

Jquery onBlur pad zeros from the left into a number


How can i using jquery to pad zeros from the left into a number to complete eleven digits just in case it did not have yet eleven digits?

How can i find the only one element i want to apply the eleven zeros? $(#myid) ? instead of input?

$(document).on('blur keyup', 'input', function() {
    padElevenZeros( $(this) );
});

Aucun commentaire:

Enregistrer un commentaire