This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** Code goes in theme functions.php **/ | |
add_filter( 'resume_manager_candidate_dashboard_login_url', 'custom_resume_manager_candidate_dashboard_login_url' ); | |
function custom_resume_manager_candidate_dashboard_login_url() { | |
return 'http://someurl.com'; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** Code goes in theme functions.php **/ | |
add_filter( 'job_manager_alerts_login_url', 'custom_job_manager_alerts_login_url' ); | |
function custom_job_manager_alerts_login_url() { | |
return 'http://someurl.com'; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_action( 'init', 'disable_bookmark_functionality' ); | |
function disable_bookmark_functionality() { | |
$subscription_product_id = '116'; // Customise me! | |
if ( ! is_user_logged_in() || ! WC_Subscriptions_Manager::user_has_subscription( get_current_user_id(), $subscription_product_id ) ) { | |
remove_action( 'single_job_listing_meta_after', array( $GLOBALS['job_manager_bookmarks'], 'bookmark_form' ) ); | |
remove_action( 'single_resume_start', array( $GLOBALS['job_manager_bookmarks'], 'bookmark_form' ) ); | |
} | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
add_action( 'post_updated', 'notify_admin_on_resume_edit' ); | |
function notify_admin_on_resume_edit( $id ) { | |
if ( 'resume' === get_post_type( $id ) && ! current_user_can( 'manage_options' ) ) { | |
wp_mail( get_option( 'admin_email' ), 'Resume Edited', 'Resume ' . $id . ' has been edited' ); | |
} | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_filter( 'job_application_form_fields', 'custom_job_application_form_fields' ); | |
function custom_job_application_form_fields( $fields ) { | |
$fields['checkbox']['value'] = 1; | |
return $fields; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_filter( 'job_manager_job_listing_data_fields', 'custom_email_job_manager_job_listing_data_fields' ); | |
function custom_email_job_manager_job_listing_data_fields( $fields ) { | |
global $post; | |
if ( ! metadata_exists( 'post', $post->ID, '_application' ) ) { | |
$fields['_application']['value'] = 'add custom email here'; | |
} | |
return $fields; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_filter( 'register_post_type_job_listing', 'custom_register_post_type_job_listing' ); | |
function custom_register_post_type_job_listing( $args ) { | |
$args['support'][] = 'thumbnail'; | |
return $args; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_filter( 'upload_size_limit', 'limit_upload_size_limit_for_non_admin' ); | |
function limit_upload_size_limit_for_non_admin( $limit ) { | |
if ( ! current_user_can( 'manage_options' ) ) { | |
$limit = '1000000'; // 1mb in bytes | |
} | |
return $limit; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_filter( 'job_application_form_fields', 'alter_upload_cv_test' ); | |
function alter_upload_cv_test( $fields ) { | |
$fields['application_attachment']['label'] = 'Custom Label'; | |
$fields['application_attachment']['description'] = 'Custom desc'; | |
return $fields; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_filter( 'gettext', 'change_resume_to_cv', 20, 3 ); | |
/** | |
* Change "resume" to "cv" | |
*/ | |
function change_resume_to_cv( $translated_text, $text, $domain ) { | |
$translated_text = str_replace( | |
array( | |
'Resume', | |
'resume' |