Welcome, Guest
Username: Password: Remember me

TOPIC: RegEx Validation: Mobile Number

RegEx Validation: Mobile Number 2 years 6 months ago #77490

  • karlo
  • karlo's Avatar
  • OFFLINE
  • Fresh Lemon
  • Posts: 3
  • Karma: 0
Hello,

I love using LimeSurvey however, I am encountering a small issue. Basically, it's just a mobile phone validation thing. The number should start with "09" and then checks the range of numbers, the operator code and then just checks 7 numbers after it. Simple as that.

Example, "09171234567" is a valid one and "09471234567" is invalid.

I tried using an online RegEx validator as well as using RegEx Buddy. It works.

However, it doesn't work with the latest version of LimeSurvey.

Here is the RegEx code:
^09(05|06|15|16|17|25|26|27|35|36|37|45|94|95|96|97|17)\d{7}$

Please help me.
The administrator has disabled public write access.

Re: RegEx Validation: Mobile Number 2 years 6 months ago #77491

  • TMSWhite
  • TMSWhite's Avatar
  • OFFLINE
  • LimeSurvey Team
  • Posts: 759
  • Thank you received: 82
  • Karma: 36
Where are you putting the Regex validation? In the question validation field? In JavaScript? Other? Can you export the question that isn't working as .lsq so we can test it?
The administrator has disabled public write access.

Re: RegEx Validation: Mobile Number 2 years 6 months ago #77493

  • karlo
  • karlo's Avatar
  • OFFLINE
  • Fresh Lemon
  • Posts: 3
  • Karma: 0
TMSWhite wrote:
Where are you putting the Regex validation? In the question validation field? In JavaScript? Other? Can you export the question that isn't working as .lsq so we can test it?

In the validation field. Here you go.
Attachments:
The administrator has disabled public write access.

Re: RegEx Validation: Mobile Number 2 years 6 months ago #77877

  • karlo
  • karlo's Avatar
  • OFFLINE
  • Fresh Lemon
  • Posts: 3
  • Karma: 0
OMG, I can't believe this. No one actually helped me out with this. Darn. Is this the open community that you call?
The administrator has disabled public write access.

Re: RegEx Validation: Mobile Number 2 years 6 months ago #77892

  • tpartner
  • tpartner's Avatar
  • OFFLINE
  • LimeSurvey Team
  • Posts: 4207
  • Thank you received: 791
  • Karma: 360
Well, that's a good way to get a response!

Complaints can be sent with our paycheques.
Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.

LimeSurvey is open-source and run entirely by volunteers so please consider donating to support the project.
The administrator has disabled public write access.
The following user(s) said Thank You: DenisChenu

Re: RegEx Validation: Mobile Number 2 years 5 months ago #77924

  • Mazi
  • Mazi's Avatar
  • OFFLINE
  • LimeSurvey Team
  • Posts: 5325
  • Thank you received: 296
  • Karma: 249
tpartner wrote:
Well, that's a good way to get a response!

Complaints can be sent with our paycheques.
Sorry that I was playing with my little daugther on Sunday afternoon instead of answering your questions, karlo!

Best regards/Beste Grüße,
Dr. Marcel Minke
(Limesurvey Head of Support)
Need Help? We offer professional Limesurvey support
Contact: marcel.minke(at)limesurvey.org'"
The administrator has disabled public write access.
Moderators: ITEd
Time to create page: 0.168 seconds
Donation Image