Show only keyboard with number on Ionic / Cordova app

I have two problems in my Ionic / Cordova application, and with a numeric keypad, that I have no way to show it.

1) Enter the password that must contain the numeric keypad. It shows an alphanumeric keyboard. If I switch to numeric, I cannot hide the entries (c *).

2) The numeric input that I have to insert the currency mask (from left to right). All the parameters that I find are run in text input.

Does anyone help me? You are welcome!

+14
android cordova keyboard ionic-framework numeric-input
source share
8 answers

I solved using CSS:

<input type="number" style="-webkit-text-security:disc"> 

Thank you all for your help!

+15
source share

I solved with tel:

 <input type="tel"> 
+14
source share

2) The numeric input that I have to insert the currency mask (from left to right). All the parameters that I find are run in text input.

Using http://www.numbox.org you can solve the second problem.

+3
source share

Old, but I had this problem.

I decided to contribute this:

  type="number" pattern="[0-9]*" 

Hope it helps.

+1
source share

I use
<ion-input type="number" pattern="\d*"></ion-input> and it works

Android keyboard

+1
source share

Try adding this to your input, onkeypress = 'return event.charCode> = 48 && & event.charCode <= 57'

0
source share
0
source share

Use the pattern attribute: <input type="tel" pattern="[0-9]*">

0
source share

All Articles