Skip to content

Instantly share code, notes, and snippets.

Last active September 19, 2015 09:01
What would you like to do?
WP Job Manager Resumes - Enable comments on resumes
// Add comment support to the post type
add_filter( 'register_post_type_resume', 'register_post_type_resume_enable_comments' );
function register_post_type_resume_enable_comments( $post_type ) {
$post_type['supports'][] = 'comments';
return $post_type;
// Make comments open by default for new resumes
add_filter( 'submit_resume_form_save_resume_data', 'custom_submit_resume_form_save_resume_data' );
function custom_submit_resume_form_save_resume_data( $data ) {
$data['comment_status'] = 'open';
return $data;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment