When I validate a required select list option that has a safe_key "0", it is always considered empty.

Please also read this webform issue #10 by quicksketch: #883626: 1st choice (keys with "0") of select options (as checkboxes) do not save nor email

I also use the webform validation module to verify if one of the checkboxes is selected. When I select the first option (zero as key value) the module prompts me that I have to select a value.
This is probably a separate bug in Webform Validation. Since the checkboxes are submitting a value of "0", it's easy to accidentally not capture the value since in PHP "0" == FALSE == NULL.

Comments

svendecabooter’s picture

Status: Active » Fixed

This issue has been addressed in HEAD.
Thanks for reporting this bug!

svendecabooter’s picture

Status: Fixed » Closed (fixed)
online services’s picture

Hi,

i have this issue when i use a RegExp on several fields, an "0" is accepted, even when i set a minimum of characters.

liam morland’s picture

Issue summary: View changes