• Hi,
    I’am try to build this registration formular :
    1) Checkbox “city”: Witch city did you visit?
    Values (“Paris”, “London”, “Berlin”)
    2) Radiobox “enjoy-paris”: Did you enjoyed Paris? (Yes/No)
    mandatory, default “yes”, displayed only when city contains “Paris”
    3) Text “why-not-paris” : Why?
    mandatory, displayed only when enjoy-paris equals No

    My tests (WordPress 4.9.5 – Twenty Sixteen – Ultimate Member V2.0.13)

    1) if i check “Paris”, “No” to Enjoy? and i dont answer to Why?, i have this error: Warning: strstr() expects parameter 1 to be string, array given in wp-content/plugins/ultimate-member/includes/core/um-actions-form.php on line 378

    Here is my correction:
    old: if ( ! strstr( $cond_value, $parent_value ) ) {
    new: if ( ! strstr( $cond_value[0], $parent_value ) ) {

    2) After that, i make the same test and the registration fails because the field Why? is empty. That’s Ok but as the form is reloaded, fields City (Paris) and Enjoy? (No) are correctly displayed while the field Why? remain masked (and the warning not visible).

Viewing 1 replies (of 1 total)
  • Thread Starter dhebert91

    (@dhebert91)

    3) When i check Enjoy: “No” and i fill the field “Why?”, if i select Enjoy: “Yes” et then “No”, the content à the field “Why” is erased.

Viewing 1 replies (of 1 total)
  • The topic ‘Chekbox and radiobox not working correctly’ is closed to new replies.