According to the description in the form actions https://docs.metabox.io/extensions/mb-frontend-submission/ I need to use the metabox name to verify the 'config['id']'.
In my case, I have many metabox IDs coupled in a frontend form. In this scenario, how can I verify and process the form actions to send an email after submission?
Please help me to use the code.
Below are the details of the content.
page id: 7896
form shortcode:
[mb_frontend_form id="job-post-title,taxonomies-1-job,job-details,job-meta-university-address" post_type="job" post_status="pending" submit_button="Submit" edit="true" ajax="true" confirmation="You have successfully submitted your job. Visit the dashboard to edit it if you wish. We will contact you soon." redirect="https://nviewscareer.com/account/jobs-submitted-dashboard/"]
ref.
add_action( 'rwmb_frontend_after_process', function( $config, $post_id ) {
if ( 'my-meta-box' === $config['id'] ) {
wp_mail( '[email protected]', 'New submission', 'A new post has been just submitted.' );
wp_safe_redirect( 'thank-you' );
die;
}
}, 10, 2 );
what to use for 'my-meta-box' in my case?
Sorry for these silly questions...