Edit Postal Code to acept only numbers

  • Posts: 29
  • Thank you received: 1
2 months 2 weeks ago #289039

-- url of the page with the problem -- : umbandaexplica.com.br/loja/
-- HikaShop version -- : 3.2.2

Hi there,

I want to know how to make the users put only numbers in the Zip Code field. Currently they can put "12365-5623" "abd2454" and so on.

Thankful.

Please Log in or Create an account to join the conversation.

  • Posts: 22339
  • Thank you received: 3478
  • MODERATOR
2 months 2 weeks ago #289043

Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.

Please Log in or Create an account to join the conversation.

  • Posts: 29
  • Thank you received: 1
2 months 2 weeks ago #289099

Hi Jerome, it worked perfectly.

But I made some changes. In the documentation speak to use only [0-9] + but this causes special characters to be used or letters. The code only causes the first character to be a number from 0-9.

I used the following code: ^ [0-9] + $ and it works perfectly. Only numbers, no letters or special characters.

Very Thanks

Please Log in or Create an account to join the conversation.

Time to create page: 0.069 seconds
Powered by Kunena Forum