Hi,
I tried to hide the frontend form depending on the user role, for example for subscribers.
In the form with MB conditional logic, with the option hide to hide the form for subscribers.
But please help me to hide the submit button from the form.
To solve this problem, I tried the following code
`
add_action( 'rwmb_frontend_before_submit_button', function( $config, $post_id ) {
if ( 'job-post-title' === $config['7896'] ) {
if( is_user_logged_in()){
die;
//return '';
}
}
}, 10, 2 );
`
In the form, I have used several forms. The form 'job-post-title' is one of them and the first form ID.
Please take a look and help me to conditionally hide the 'Submit' button.