Set "Inputmode" on a Currency Field to a Decimal

Please note that this is now available as a plugin for easier installation. While you can use this document as a reference, the recommended method to add…

  • Not yet re-checked
  • Classic builder

Moved from our previous help site and not yet re-checked against the current product. Last edited Sep 20, 2024.

Screenshot for “Set "Inputmode" on a Currency Field to a Decimal”

This customization can be beneficial for many reasons. For example, it can be helpful on an app targeted purely at mobile users.

Step 1

Copy & paste this code into the footer of the site:

Text
<script src="https://cdnjs.cloudflare.com/ajax/libs/inputmask/4.0.9/jquery.inputmask.bundle.min.js"></script>
Screenshot for “Set "Inputmode" on a Currency Field to a Decimal”

Step 2

Find the ID of the field you wish to use:

Screenshot for “Set "Inputmode" on a Currency Field to a Decimal”

Step 3

Add the following code to the JavaScript of the page, be sure to change the field ID to the ID from step 2.

Text
var flag = false;

function checkFlag() {
    if (flag === false) {
        if ($(’#field0DzjGaNYp1’).html() !== undefined) {
            flag = true;
        }
        window.setTimeout(checkFlag, 100);
    } else {
        var im = new Inputmask(‘99.99’);
        im.mask($(’#field0DzjGaNYp1’));

    }
}
checkFlag();
Screenshot for “Set "Inputmode" on a Currency Field to a Decimal”

Original Community Post:

Set "inputmode" on a currency field to "decimal"? - Community Discussions / How Do I - Tadabase Community

Was this page helpful?

Something wrong or missing on this page? Tell us.