Search button in header is hidden for each postpage
-
By default the search button in the header main menu is hidden.
In the file:
/auxin/auxin-include/include/templates/templates-header.phpYou will find the function:
auin_get_header_layout()In this function you will find this piece of code:
if ( 'default' === $add_search = auxin_get_post_meta( $post, 'page_header_search_button' ) ) { $add_search = auxin_get_option( 'site_header_search_button' ); }
But the function auxin_get_post_meta( $post, ‘page_header_search_button’ ) will return null because this option doesn’t exist. You can’t set in in the wp-admin section. The if statement will fail and the default value of $add_search = false will be used.
Solution:
Add option to toggle the search button per blog in wp-admin or check the return value correctly so that $add_search = auxin_get_option( ‘site_header_search_button’ ); will be used.Thank you.
Tim from Timdehoog.nl
- The topic ‘Search button in header is hidden for each postpage’ is closed to new replies.