Basic Phone Input Mask With Pure JavaScript – phone-mask

Category: Form , Javascript | November 30, 2018
Author:Bwca
Views Total:12,456 views
Official Page:Go to website
Last Update:November 30, 2018
License:MIT

Preview:

Basic Phone Input Mask With Pure JavaScript – phone-mask

Description:

phone-mask is a really simple JavaScript plugin to make custom masks on phone inputs.

How to use it:

Import the phone-mask library into the document.

<script src="phone-mask.min.js"></script>

Add the class masked-phone to the phone input and create the mask in the data-phonemask attribute:

<input type="tel" name="tel[]" class="masked-phone" data-phonemask="+1 (___)__-___-___">

You Might Be Interested In:


Leave a Reply