I have written a new validation

CommentFileSizeAuthor
webform_validation.validators.zip4.82 KBlyknart
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

svendecabooter’s picture

Status: Patch (to be ported) » Needs work

Can you post this as a patch, and elaborate a bit more on what this does exactly? (e.g. provide a use case or example)

lyknart’s picture

This solution can simply be, in the case of a multiple-choice, you can block the sending of the form until the user correctly answers the question or questions.
The method "specific values" can create an OR between the responses. In this case it is an AND.
I made a solution appears in the original attachment.

Exemple:

Question 1 :
1|A
2|B
3|C

Validation => 2 AND 3

If i answer :
1 = false
2 = false
3 = false
1 AND 2 = false
1 AND 3 = false
2 AND 3 = true => go to next question / send to webform

Liam Morland’s picture

Version: 7.x-1.0-rc1 » 7.x-1.1
Category: task » feature

Please post this as a patch against the latest development version.

Liam Morland’s picture

Version: 7.x-1.1 » 7.x-1.x-dev
Issue summary: View changes