This file contains 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 your own function to filter the fields | |
add_filter( 'submit_job_form_fields', 'remove_listify_submit_job_form_fields', 9999999999 ); | |
// This is your function which takes the fields, modifies them, and returns them | |
// You can see the fields which can be changed here: https://github.com/mikejolley/WP-Job-Manager/blob/master/includes/forms/class-wp-job-manager-form-submit-job.php | |
function remove_listify_submit_job_form_fields( $fields ) { | |
if( ! isset( $fields['company'] ) ) return $fields; |
This file contains 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_filter( 'field_editor_workscout_overview_output_csv', '__return_false' ); |
This file contains 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 | |
function smyles_custom_posts_search($search, $wp_query) { | |
global $wpdb; | |
if (empty($search)) { | |
return $search; // skip processing - no search term in query | |
} | |
$q = $wp_query->query_vars; |
This file contains 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 | |
public function give_user_subscription( $product, $user_id, $note = '' ){ | |
// First make sure all required functions and classes exist | |
if( ! function_exists( 'wc_create_order' ) || ! function_exists( 'wcs_create_subscription' ) || ! class_exists( 'WC_Subscriptions_Product' ) ){ | |
return false; | |
} | |
$order = wc_create_order( array( 'customer_id' => $user_id ) ); |
This file contains 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_filter( 'submit_job_form_fields', 'smyles_custom_default_per_package', 101 ); | |
function smyles_custom_default_per_package( $fields ) { | |
$packages_config = array( | |
// The key should be the ID of the product (look at the ID when editing the product in the URL bar) | |
'11111' => array( | |
// Array key should be the exact meta key | |
'job_type' => 'freelance', |
This file contains 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_filter( 'submit_resume_steps', 'replace_resume_done_with_redirect' ); | |
function replace_resume_done_with_redirect( $steps ) { | |
$steps['done'] = array( | |
'priority' => 30, | |
'handler' => function() { | |
do_action( 'resume_manager_resume_submitted', WP_Resume_Manager_Form_Submit_Resume::instance()->get_resume_id() ); | |
$job_id = WP_Resume_Manager_Form_Submit_Resume::instance()->get_job_id(); |
This file contains 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_filter( 'submit_job_form_fields', 'smyles_remove_fields_by_user_role', 999999999999 ); | |
function smyles_remove_fields_by_user_role( $fields ){ | |
$fields_to_remove = array( 'job_salary', 'some_other_meta_key' ); | |
$user = wp_get_current_user(); | |
if ( in_array( 'employer', (array) $user->roles ) ) { |
This file contains 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
.marker-cluster-small { | |
background-color: rgba(181,226,140,.6) | |
} | |
.marker-cluster-small div { | |
background-color: rgba(110,204,57,.6) | |
} | |
.marker-cluster-medium { | |
background-color: rgba(241,211,87,.6) |
This file contains 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 | |
/** | |
* Get current site Theme Name | |
* | |
* This method will get the theme name by default from parent theme, and | |
* if not set it will return the textdomain. | |
* | |
* | |
* @since 1.3.5 |
This file contains 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_filter( 'new_job_application', 'smyles_redirect_after_new_job_application', 10, 2 ); | |
function smyles_redirect_after_new_job_application( $application_id, $job_id ) { | |
// You must manually input the URL to redirect to below, currently there is no way to pull this value as it is not | |
// saved in any settings or configurations | |
// This also does not show any kind of notification to the user that their application has been submitted. | |
// It is recommended that you instead use a template override (https://wpjobmanager.com/document/template-overrides/) |