Home › Forums › Jevelin Theme › Page template – get_header not working
Home › Forums › Jevelin Theme › Page template – get_header not working
Hi,
Hope this is my last question. I installed a plugin which manages calendars. When a single event page loads, the method get_header do not loads the right header used as primary header into the theme options.
I selected header-4 for all my pages, but the event slug page keeps loading the header-1 template.
I tried also changing the get_header method with the get_template_part() method, but it loads two headers. Is there a template file I can use to create single-page templates?
Thank you in advance,
BR.
Hi @miky158,
I hope you are well today and thank you for your question.
Which layout to display on which pages are managed by the following theme function jevelin_header_layout added in the theme file /jevelin/inc/helpers.php on line number 570 so you can edit it in the Jevelin child theme to display appropriate headers.
function jevelin_header_layout() { $header_layout1 = esc_attr( jevelin_post_option( jevelin_page_id(), 'header_layout', '1' ) ); $header_layout2 = esc_attr( jevelin_option( 'header_layout', '1' ) ); if( !is_search() && !is_singular('product') && !is_archive() && !is_home() && !is_404() ) : return ( isset($header_layout1) && $header_layout1 && $header_layout1 != 'default' ) ? $header_layout1 : ( ( isset($header_layout2) && $header_layout2 ) ? $header_layout2 : '1' ); else : return $header_layout2; endif; }
Best regards,
Shufflehound team