Windows phone : Masked input telephone number


#1

How can I mask telephone no? I have used jquery.maskedinput plugin for ioS and android but for windows it is not working.

Thanks in advance.


#2

Add a class (say masked-input) to your element:

 <input type="tel" class="masked-input">

…and then in styles.css add:

.masked-input {
    text-security:disc;
    -webkit-text-security:disc;
    -mox-text-security:disc;
}

This will work on webkit browsers like Chrome or Safari but I haven’t tried it on Firefox or IE.


#3

No it is not working.

I need to take input in specific format like ___ - ___ - ____ , where user can only type in _ field.


#4

I did this earlier. I looked at the code, i did some magic there before, which i cant really understand right now :smile:

I used ngChange, and then some regexp … all i can remember that i couldn’t use ngChange and ngPattern at the same time somehow.

I think i can make a codepen about it tomorrow.


#5

I have replaced it with http://github.com/assisrafael/angular-input-masks