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 //remove in an existing file | |
add_filter( 'sensei_question_answer_notes', 'latex_markup' ); |
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 //remove in an existing file | |
add_filter( 'wcpl_get_job_packages_args', 'bk_show_hidden_job_packages'); | |
function bk_show_hidden_job_packages( $args ) { | |
unset( $args['meta_query'] ); | |
return $args; | |
} |
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
add_action( 'init', 'bk_remove_jobfeed' ); | |
function bk_remove_jobfeed(){ | |
global $wp_rewrite; | |
if ( ( $key = array_search( 'job_feed', $wp_rewrite->feeds ) ) !== false ) { | |
unset( $wp_rewrite->feeds['jobfeed'] ); | |
remove_all_actions( 'do_feed_job_feed' ); | |
} | |
} |
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 //remove in an existing file | |
add_action( 'woocommerce_order_status_completed', 'bk_force_add', 9 ); | |
add_action( 'woocommerce_order_status_completed', 'bk_force_drop', 11 ); | |
function bk_force_add() { | |
add_filter( 'pre_option_job_manager_submission_requires_approval', '__return_false' ); | |
} | |
function bk_force_drop() { |
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
add_filter( 'wp_mail_from', 'bk_from_addy'); | |
function bk_from_addy( $email ) { | |
$email = "[email protected]"; | |
return $email; | |
} |
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
add_filter( 'job_manager_job_listing_data_fields', 'custom_job_manager_job_listing_data_fields' ); | |
function custom_job_manager_job_listing_data_fields( $fields ) { | |
// Here we target one of the job fields (location) and change it's placeholder | |
$fields['_package_id'] = array( | |
'label' => "Package ID", | |
'placeholder' => "None", | |
'description' => '', | |
'type' => 'package_display' |
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 //remove in an existing file | |
add_action( 'before_get_job_listings', 'bk_remove_password_posts' ); | |
add_action( 'after_get_job_listings' , 'bk_clean_password_posts' ); | |
function bk_remove_password_posts() { | |
add_filter( 'posts_where', 'bk_password_post_filter' ); | |
} | |
function bk_clean_password_posts() { |
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
add_filter( 'the_password_form', 'bk_custom_password_form' ); | |
function bk_custom_password_form( $output ){ | |
$output = '<form action="' . esc_url( site_url( 'wp-login.php?action=postpass', 'login_post' ) ) . '" class="post-password-form" method="post"> | |
<p>' . __( 'This content is password protected. To view it please enter your password below:' ) . '</p> | |
<p><label for="' . $label . '">' . __( 'Password:' ) . ' <input name="post_password" id="' . $label . '" type="password" size="20" /></label> <input type="submit" name="Submit" value="' . esc_attr_x( 'Enter', 'post password form' ) . '" /></p></form> | |
'; | |
return $output; | |
} |
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 // remove in an existing file | |
add_action( 'admin_notices', 'bk_output_vars' ); | |
function bk_output_vars(){ | |
echo "The port is " . $_SERVER['SERVER_PORT']; | |
echo "<br>The host is " . $_SERVER['HTTP_HOST']; | |
} |
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 //do not add to an existing file | |
add_action('admin_notices', 'bk_server_port_output'); | |
function bk_server_port_output(){ | |
echo "Server port is " . $_SERVER['SERVER_PORT']; | |
} |