Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #682681

    Can I make the default header layout be Transparent? So I don’t have to go in and change the header selection on every page or post I do? The large website I am working on will have all pages and posts have the transparent header.

    #682685

    Hi Lane!

    Please add following code to Functions.php file of your child theme in Appearance > Editor

    
    add_action( 'after_setup_theme', 'enfold_customization_product_switch' );
    function enfold_customization_product_switch(){
    	add_filter('avf_builder_elements', 'avf_builder_elements_mod');
    }
    
    function avf_builder_elements_mod($elements)
    {
    	$counter = 0;
        foreach($elements as $element)
        {
    		if($element['id'] == 'header_transparency')  {
                $elements[$counter]['std'] = 'header_transparent ';
            }
            $counter++;
        }
    	return $elements;
    }

    and new pages would have transparent header by default

    Regards,
    Yigit

    #684179

    I tried to do this but it seems to be breaking site? Confused about the child theme a bit. Do I need to copy the entire functions file into my child theme? Or can I just add code like this to a ‘new’ blank php file?

    Thanks!

    #684182

    Hey!

    You can copy paste the code as is to your child theme’s functions.php file. If you would like us to look into it, please post FTP logins and WP admin logins here privately.

    Regards,
    Yigit

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.