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
| global $woothemes_sensei; | |
| global $avia_config; | |
| remove_action( 'sensei_before_main_content', array( $woothemes_sensei->frontend, 'sensei_output_content_wrapper' ), 10 ); | |
| remove_action( 'sensei_after_main_content', array( $woothemes_sensei->frontend, 'sensei_output_content_wrapper_end' ), 10 ); | |
| add_action('sensei_before_main_content', 'my_theme_wrapper_start', 10); | |
| add_action('sensei_after_main_content', 'my_theme_wrapper_end', 10); | |
| function my_theme_wrapper_start() { | |
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 | |
| function limit_upload_size_limit_for_non_admin( $limit ) { | |
| if ( ! current_user_can( 'manage_options' ) ) { | |
| $limit = 1000000; // 1mb in bytes | |
| } | |
| return $limit; | |
| } | |
| add_filter( 'upload_size_limit', 'limit_upload_size_limit_for_non_admin' ); |
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( 'login_url', 'my_login_page', 10, 2 ); | |
| function my_login_page( $login_url, $redirect ) { | |
| return home_url( '/login-page/?redirect_to=' . $redirect ); | |
| } |
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_applications_past_args', 'change_past_application_args'); | |
| function change_past_application_args( $args ) { | |
| $args['posts_per_page'] = 5; // Number of past applications to display on each page. | |
| $args['offset'] = ( max( 1, get_query_var( 'paged' ) ) - 1 ) * $args['posts_per_page']; | |
| 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
| function change_resume_slug( $args ) { | |
| $args['rewrite']['slug'] = _x( 'cv', 'Resume permalink - resave permalinks after changing this', 'wp_job_manager_resumes' ); | |
| return $args; | |
| } | |
| add_filter( 'register_post_type_resume', 'change_resume_slug' ); |
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( 'wcpl_get_job_packages_args', 'bk_show_hidden_job_packages'); | |
| function bk_show_hidden_job_packages( $args ) { | |
| unset( $args['tax_query'][1] ); | |
| 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( 'submit_job_form_fields', 'custom_submit_job_form_fields' ); | |
| function custom_submit_job_form_fields( $fields ) { | |
| $fields['job']['job_type']['default'] = "freelance"; | |
| 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
| function job_manager_set_allowed_deletion_period() { | |
| return 3; | |
| } | |
| add_filter( 'job_manager_job_listing_allowed_deletion_period', 'job_manager_set_allowed_deletion_period' ); |
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( 'sensei_before_main_content', 'sensei_conditional_lesson_display', 10 ); | |
| function sensei_conditional_lesson_display() { | |
| if( !is_singular('course') ) return; | |
| global $post, $current_user, $woothemes_sensei; | |
| $is_user_taking_course = Sensei_Utils::user_started_course( $post->ID, $current_user->ID ); | |
| if ( ! ( $is_user_taking_course || sensei_all_access() ) ) { | |
| remove_action( 'sensei_single_course_content_inside_after' , array( 'Sensei_Course','the_course_lessons_title'), 9 ); |
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 | |
| // Define your keys here | |
| define( 'RECAPTCHA_SITE_KEY', 'XXX' ); | |
| define( 'RECAPTCHA_SECRET_KEY', 'XXX' ); | |
| // Enqueue Google reCAPTCHA scripts | |
| add_action( 'wp_enqueue_scripts', 'recaptcha_scripts' ); | |
| function recaptcha_scripts() { | |
| wp_enqueue_script( 'recaptcha', 'https://www.google.com/recaptcha/api.js' ); |
NewerOlder