Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author James Laws

    (@jameslaws)

    Ninja Forms does this but only for a fixed number of digits. To make it flexible you would need to write your own javascript.

    Thread Starter Jocla

    (@jocla)

    sorry i don’t understand. Ninja forms does what?

    i need three conditions

    a) input righ to left
    b) input only numbers
    c) input commas or points every three digits (USD mask ending in two digits 0.00)

    if not possible, one or two of those three condition is good.

    Plugin Author James Laws

    (@jameslaws)

    Ninja Forms allows you to do the first two of these in the field settings Custom Masks option for text fields. Meaning you could create mask by adding $999,999,999.

    That would force the field to only accept nine digits separated with commas and beginning with a dollar sign.

    The last option would require you writing custom javascript. Meaning the Ninja Forms custom mask only allows you to create a mask for a fixed size. To make it where the number could anywhere from 1.00 to 1,000,000,000.00 would require custom javascript. Ninja Forms does not do this by default.

    orionghf

    (@orionghf)

    It doesn’t only support “fixed number of digits” the javascript used supports optional place in the field using “?”
    where everything written after “?” is considered optional ..

    for example the mask is : “(999) 999-9999? x99999”
    so every character after the “?” is considered optional for the user

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘need input mask, only numbers’ is closed to new replies.