Okay
  Public Ticket #2329176
Force Dark Logo on individual posts
Closed

Comments

  • katiemac00 started the conversation

    Is it possible to force the logo and the main navigation to be the logo that I have uploaded as the dark logo? Same with the color of text I've selected for the dark text on all of the individual blog posts?

  •  8,992
    Tahir replied

    Hey Again,

    Yes you can use these options : http://prntscr.com/rhd0hl . 

    Best


    ThemeNectar Support Team 

  • katiemac00 replied

    Is there a way to set it up so I don't have to do that on every single post? I am redesigning a site that has 150 blog posts and I'd rather not go into each post just to change those settings. 

  •  1,089
    ThemeNectar replied

    Hey katiemac00,

    You can accomplish that adding the following snippet into your child theme functions.php:

    add_action('init','salient_child_update_all_trans_coloring');
    function salient_child_update_all_trans_coloring() {
        
        $args = array(
                'post_type' => 'post', 
                'post_status' => 'publish', 
                'posts_per_page'   => -1 
        );
        $posts = get_posts($args);
        
        foreach ( $posts as $post ) {
                update_post_meta( $post->ID, '_force_transparent_header_color', 'dark' );
        }
    }
    

    Once that's in, simply load any page once and all will be updated - you can then delete the snippetsmile.png

    Cheers