Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Customize ios keyboard to show numeric keyboard

I am working on a hybrid apps where I need to display numeric keyboard with dot and comma for iOS. I tried the pattern [0-9] with type as number. It works for android but does not show dot/comma for iOS. Anyone has any idea how to achieve this for iOS ? i tried searching for cordova plugin. Did not get any. I created a custom keyboard in angular. But it is having some delay for iOS when i provide any input. I need below attached keyboard in html5 input field. For ios i don't get dots using "input type="number" min="0" inputmode="numeric" pattern="[0-9]*"".

Please see attached screenshot

like image 984
Bhaskar Hazarika Avatar asked May 18 '16 07:05

Bhaskar Hazarika


People also ask

How do I get my iPhone keyboard to show numbers?

If a keyboard isn't already visible, tap the Show Keyboard button , then tap the Formula Keyboard button to begin editing a formula. To quickly enter a number or symbol on an iPad, drag down on a key and then lift your finger, or switch to the numeric keyboard on iPhone.

Can you change iPhone keyboard to have numbers?

When you are typing in iOS 11, you can swipe down on the upper row of letters to add numbers.

How do I put numpad on my iPhone?

About Numpad Just tap the additional keyboards button to access Numpad.

Can you customize iOS keyboard?

You can adjust the onscreen (software) keyboard on iPhone. If you use an external (hardware) keyboard with iPhone, you can customize keyboard shortcuts and change settings such as the key repeat rate.


1 Answers

2019 Update

For anyone coming from Google looking for a working solution, this is now possible with the inputmode attribute as of iOS 12.3.

So something like <input type="number" pattern="[0-9]*" inputmode="decimal"> will show the numeric keyboard with a dot/comma for Android/iOS 12.3+, and the regular numeric keyboard for older iOS devices - note that inputmode has to be set to "decimal".

More info available on MDN.

like image 147
Ryan Zhang Avatar answered Oct 08 '22 03:10

Ryan Zhang