Support Forum
Support › Meta Box Conditional Logic › Conditional Logic does not work with MB Frontend Submission
Hello,
I want to use Meta Box Conditional Logic with MB Frontend Submission.
The conditional logic works well in admin, but not in frontend.
Can you do something ?
Regards,
Hi there,
Thank you for your report. Can you share the code you use to register meta box?
Dear ludovic,
You're right. Conditional Logic currently only works in admin. I'll check the plugin and release new update asap!
Thank you !
I have the same issue. I am commenting here to receive the follow-up reply when the update is complete. No need for any other response.
Thanks for the great support!
Hi,
Is there any update on conditional logic for front-end forms?
Thanks!
Hi buddy!
Please update to the latest version (1.5) which supported frontend submission extension.
Cheers!
Just installed the newest version and I'm not having any luck front-end or back-end.
It is writing both "display:none" and "visibility:hidden" to the hidden divs.
Example:
<div class="rwmb-field rwmb-select-wrapper" data-visible="hidden" style="display: none;visibility: hidden;"><div class="rwmb-label">
It seems like that should not be the case. If I remove the inline styles in the dev tools, I can get them to appear.
Here is a sample of one of my conditional fields for reference:
array(
'id' => $prefix . 'financial_assistance_choice',
'name' => esc_html__( 'Did you provide financial assistance or an incentive?', 'obh' ),
'type' => 'radio',
'placeholder' => '',
'options' => array(
esc_html_x( 'Yes', 'Value for radio select', 'obh' ) => esc_html__( 'Yes', 'obh' ),
esc_html_x( 'No', 'Value for radio select', 'obh' ) => esc_html__( 'No', 'obh' ),
),
'inline' => true,
),
array(
'id' => $prefix . 'financial_assistance_types',
'name' => esc_html__( 'Which type of assistance?', 'obh' ),
'type' => 'select',
'placeholder' => 'Select the Assistance Type',
'visible' => [ $prefix . 'financial_assistance_choice', '=', 'yes'],
'options' => obh_print_at_field_vars(),
'toggle_type' => 'visibility'
),
I recently added the "toggle_type" setting as an attempted remedy but it did not solve the issue.
Thoughts?
Aw shoot... As soon as I posted this I realized the problem. I have the "Yes" as the value for the option capitalized and the "yes" for the visibility option lowercase.
All works as expected now.
Thanks for the update!