[Custom Masks] CustomMasks

[Custom Masks] CustomMasks

  
Forge Component
(24)
Published on 19 Sep by Marcelo Ferreira
24 votes
Published on 19 Sep by Marcelo Ferreira

Hi, I'm trying to have the plugin CustomMasks perform a check on a phone number.
This number has to start with number 0 and has to be exactly 10 digits long.
example: 0612345678

I've tried the following MaskDefinitions, but couldn't get it to work.

SyntaxEditor Code Snippet

"(0)999999999"
"0{1}9{9}"

Anyone able to help getting a good MaskDefinition?

Take a look at this component: http://www.outsystems.com/forge/component/621/jqueryinputmask/

You can customize it to work with translations, as stated in its documentation: https://igorescobar.github.io/jQuery-Mask-Plugin/docs.html

João Melo wrote:

Take a look at this component: http://www.outsystems.com/forge/component/621/jqueryinputmask/

You can customize it to work with translations, as stated in its documentation: https://igorescobar.github.io/jQuery-Mask-Plugin/docs.html

That is your own plugin right?


Yes, customizing it must be very simple, but let me know if you need any help to customize it.

Solution

Something like this "0999999999" should work, you need to validate the length on submit or customize the component to execute something on the isComplete event.


Solution