Let suppose we have one text custom field and this customfield should be in this format:
1111 **** **** 1111 - in such format, only first 4 digits and 4 last digits must be entered
How can I do this using validator?
Hi @Jamil Rahimov ,
I'm probably still struggling with the understanding of your use case, so could you please provide a couple of examples for valid inputs?
Assuming the requirement is
an expression matching this would be
^\d{4}\s\w{4}\s\w{4}\s\d{4}$
Cheers
Thorsten
@Thorsten Letschert _Decadis AG_
Examples:
4942 **** **** 7452
2514 **** **** 5893
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hey @Jamil Rahimov ,
if you're after the '*' symbols, please use
^\d{4}\s\*{4}\s\*{4}\s\d{4}$
Cheers
Thorsten
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@Thorsten Letschert _Decadis AG_
Thanks a lot!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@Thorsten Letschert _Decadis AG_ has the right expression from what I can see.
You could try this with ProForma Lite (free) by requiring users to match a regex pattern.
Here's what that looks like in the form builder:
I am on the ProForma team, but thought I'd share this in case it helps get you what you need.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@Peter Preston
These are examples which this expression should check:
Examples:
4942 **** **** 7452
2514 **** **** 5893
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You'll need a scripting app, or something that provides clever validators to do this.
There are several apps that provide regular expression validators, I'd reach for one of those first (unless you have a load of other needs that bigger apps like Scriptrunner or Powerscripts might help with as well as being able to provide such a validator)
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@Nic Brough -Adaptavist-
I tried Validation based on regular expression of JWT plugin but it didn't work for me.
Maybe I wrote something wrong
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
That app has worked for me in the past. I'm not a regex expert, I'd have to guess that there is something wrong in that?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.