Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #333437

    Hello,

    I am using “Header with bottom menu + social media icons” for home page and for 80% of the pages. It shows main-logo on the left.

    There are two departments that requires different header layout – “department-logo at center and bottom menu” and main-logo and company motto on the left and right respectively. There are a dozen of pages fall under each department.

    I understand that enfold theme not support for showing multiple layouts at the same time. I am working on custom template, custom header and custom helper-main-menu php files using child theme.

    To my understanding, avia_header_setting(); pass the layout setting for header to helper-main-menu-custom1.php. Correct me if I am wrong.

    My question is , is there any way to overwrite those header setting coming from backend of enfold theme to my custom helper-main-menu-custom1.php and force it to use fixed setting for “logo center and bottom menu” header layout?

    And if I want to add image or text-block on left and right, how can I do it?

    Thanks in advance!

    #334432
    #335685
    This reply has been marked as private.
    #337587

    Hi Zaw Zaw,

    Open /enfold/functions-enfold.php and look for this lines:

    //overwrite with custom fields if they are set
    $post_id = avia_get_the_id();
    

    Replace them by this:

    //overwrite with custom fields if they are set
    $post_id = avia_get_the_id();
    if($post_id == 3847) $settings['header_shrinking'] = 'av_header_shrinking_disabled';

    You can also put the whole modified avia_header_setting function in your child theme functions.php file.

    Regards,
    Josue

    #340899

    Dear Josue,

    Thanks for pointing the right place for modification. I use page template check and following codes work for me.

    		//overwrite with custom fields if they are set
    		$post_id = avia_get_the_id();
    		if ( is_page_template( 'template-gsir.php' ) )   $settings['header_shrinking'] = 'av_header_shrinking_disabled';

    Many thanks!
    Zaw Zaw

Viewing 5 posts - 1 through 5 (of 5 total)
  • The topic ‘Different Header layout for custom template’ is closed to new replies.