admin管理员组

文章数量:1221752

In my angularjs app, i have two input fields with type="text", pls see the plunkr here.

The problem is that the currency formatting is not possible for input type="number".

So it it possible to bring up Numeric keyborad for mobile devices when the focus move to input type="text"?

Please help

In my angularjs app, i have two input fields with type="text", pls see the plunkr here.

The problem is that the currency formatting is not possible for input type="number".

So it it possible to bring up Numeric keyborad for mobile devices when the focus move to input type="text"?

Please help

Share Improve this question edited Nov 12, 2014 at 9:23 Rory McCrossan 338k41 gold badges320 silver badges351 bronze badges asked Nov 12, 2014 at 9:21 IrshuIrshu 8,4468 gold badges55 silver badges66 bronze badges
Add a comment  | 

3 Answers 3

Reset to default 17

use "tel" I'm sure this will solve your problem. this will allow you to input alphabates also but it will open numeric keypad

<input type="tel">

Add pattern to it.

<input type="text" pattern="\d*">

Try the below. Additionally you can add "ng-pattern" to manage validation messages etc.

<input type="text" pattern="[0-9]*">

本文标签: