• 1

Read this first!

We do not monitor these forums. The forum is provided to exchange information and experience with other users ONLY. Forum responses are not guaranteed.

However, please submit a ticket if you have an active subscription and wish to receive support. Our ticketing system is the only way of getting in touch with RSJoomla! and receiving the official RSJoomla! Customer Support.

For more information, the Support Policy is located here.

Thank you!

TOPIC: Custom validation rules for UK Postcode

Custom validation rules for UK Postcode 9 years 3 months ago #33894

  • sam.samiei
  • sam.samiei's Avatar
  • OFFLINE
  • Junior Boarder
  • Posts: 23
  • Thank you received: 1
Hi, I'm using the following Regex Syntax to validate a UK postcode:

the validation works fine but i need to allow only Postcodes inside London and my question is how can i run a separate validation on same texbox field.

these are the postcodes allowed:
N1 to N22
NW1 to NW11
W1 to W14
EC1, EC2, EC3, EC4, WC1, WC2
E1 to E18
SE1 to SE28
SW1V, SW1X, SW1P, SW1H, SW1E, SW1A, SW1Y, SW1W, SW1 to SW20
HA0 to HA9
EN1 to EN8

and i was thinking to check the first 2 character entered and see if it match the above and if not return a error message.
any help appreciated.
thanks
Last Edit: 8 years 10 months ago by sam.samiei.
The administrator has disabled public write access.

Custom validation rules for UK Postcode 9 years 3 months ago #33895

  • alexp
  • alexp's Avatar
  • OFFLINE
  • RSJoomla! Official Staff
  • Posts: 2253
  • Thank you received: 180
Why not create your own custom validation rule ? Instructions available here:

https://www.rsjoomla.com/support/documentation/rsform-pro/customizing-rsform-pro/custom-validation-rules.html
Please note: my help is not official customer support. To receive your support, submit a ticket by clicking here
Regards,
RSJoomla! Development Team
The administrator has disabled public write access.

Custom validation rules for UK Postcode 9 years 3 months ago #33913

  • sam.samiei
  • sam.samiei's Avatar
  • OFFLINE
  • Junior Boarder
  • Posts: 23
  • Thank you received: 1
Hi, Thanks for reply. I managed to get a new Regex that checks that the Postcode is inside London. I'm not sure how can I check the postcode against 2 Regex.
Last Edit: 8 years 10 months ago by sam.samiei.
The administrator has disabled public write access.

Custom validation rules for UK Postcode 9 years 3 months ago #33919

  • alexp
  • alexp's Avatar
  • OFFLINE
  • RSJoomla! Official Staff
  • Posts: 2253
  • Thank you received: 180
The regex rules can be combined, but it does require a pretty good understanding of these. Personally i would still recommend going for a custom validation rule (you can use the existing regex definitions to combine them in a single validation rule).
Please note: my help is not official customer support. To receive your support, submit a ticket by clicking here
Regards,
RSJoomla! Development Team
The administrator has disabled public write access.

Custom validation rules for UK Postcode 9 years 3 months ago #33920

  • sam.samiei
  • sam.samiei's Avatar
  • OFFLINE
  • Junior Boarder
  • Posts: 23
  • Thank you received: 1
I tried with custom validation but I don't really know how that works. Do you offer paid customisation?
It's hard to find developer who specialise in RSForm.
The administrator has disabled public write access.

Custom validation rules for UK Postcode 9 years 3 months ago #33923

  • alexp
  • alexp's Avatar
  • OFFLINE
  • RSJoomla! Official Staff
  • Posts: 2253
  • Thank you received: 180
RSJoomla! does not provide customization services.
Please note: my help is not official customer support. To receive your support, submit a ticket by clicking here
Regards,
RSJoomla! Development Team
The administrator has disabled public write access.
  • 1

Read this first!

We do not monitor these forums. The forum is provided to exchange information and experience with other users ONLY. Forum responses are not guaranteed.

However, please submit a ticket if you have an active subscription and wish to receive support. Our ticketing system is the only way of getting in touch with RSJoomla! and receiving the official RSJoomla! Customer Support.

For more information, the Support Policy is located here.

Thank you!