Created
March 25, 2020 08:16
-
-
Save yousufansa/7f357e5dd8856f35d3885f69d96884f2 to your computer and use it in GitHub Desktop.
Jobhunt - Replace Job Location With Job Category on Header Search 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
if( ! function_exists( 'jh_child_job_header_search_block_enable_categories' ) ) { | |
function jh_child_job_header_search_block_enable_categories( $args ) { | |
if( is_post_type_archive( 'job_listing' ) || is_page( jh_wpjm_get_page_id( 'jobs' ) ) ) { | |
$args['show_category_select']= true; | |
} | |
return $args; | |
} | |
} | |
add_filter( 'jobhunt_job_header_search_block_args', 'jh_child_job_header_search_block_enable_categories' ); |
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
.job-search-block .job-search-location { | |
display: none !important; | |
} | |
.post-type-archive-job_listing .site-content-page-header .job-search-block .job-search-category { | |
display: block; | |
} | |
.post-type-archive-job_listing .site-content-page-header .job-search-block .job-search-category select { | |
height: 100%; | |
} | |
@media (min-width: 768px) { | |
.post-type-archive-job_listing .site-content-page-header .job-search-block .job-search-category { | |
flex: 0 0 30.8333333333%; | |
max-width: 30.8333333333%; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment