job_bm_company_reviews_submit_errors

Add custom input fields

add_action('job_bm_company_reviews_form', 'job_bm_company_reviews_form_custom_input');

function job_bm_company_reviews_form_custom_input($company_id){

    ?>
    <div class="form-field-wrap">
        <div class="field-title"><?php echo __('Custom input field','job-board-manager-company-profile'); ?></div>
        <div class="field-input">
            <input type="text" name="custom_input" value="">
            <p class="field-details"><?php echo __('Custom input field description.','job-board-manager-company-profile'); ?>
            </p>
        </div>
    </div>
    <?php

}

validated data for custom input field

add_filter('job_bm_company_reviews_submit_errors','job_bm_company_reviews_submit_errors_custom',90,2);

function job_bm_company_reviews_submit_errors_custom($error, $post_data){

    if(empty($post_data['custom_input'])){

        $error->add( 'custom_input', __( 'ERROR: Custom input is empty.', 'job-board-manager-company-profile' ) );
    }

    return $error;

}

View post on imgur.com