Check box default value

  • Posts: 80
  • Thank you received: 0
6 years 5 months ago #293561

-- HikaShop version -- : 3.4
-- Joomla version -- : 3.8.7
-- PHP version -- : 7.0


Hello,

I created a Checkbox custom field for the registration form, but I cannot set the default value to unchecked.
It does not work when I uncheck the Default value and Save it.
It would be necessary to be unchecked by default for the privacy policy checkbox because of the GDPR.
The solution to change the value to 0 does not work. Could you please assist me?
Thanks

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

  • Posts: 82867
  • Thank you received: 13374
  • MODERATOR
6 years 5 months ago #293562

Hi,

Please provide a screenshot of the settings of your custom field.

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

  • Posts: 80
  • Thank you received: 0
6 years 5 months ago #293578

Hi Nicolas, please find screenshots as requested.

Attachments:

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

  • Posts: 82867
  • Thank you received: 13374
  • MODERATOR
6 years 5 months ago #293604

Hi,

You need to enter something in the "value" field of the values area of your custom field. Then, you'll see that you can properly set the default value and that it will work properly on the frontend.
If you don't, then when the checkbox is checked it will be considered as "empty" and empty is also considered as not checked and thus the checkbox won't work properly.

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

  • Posts: 80
  • Thank you received: 0
6 years 5 months ago #293649

Fine! It works. Thanks a lot for your help.

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

Time to create page: 0.065 seconds
Powered by Kunena Forum