Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
    Posts
  • #18363
    osaczenitram
    Member

    Hello, i hope i can get some help with my site: http://www.eduardolaveglia.com/
    I have set up a heder image that replaces the original one (the one of the Budha that comes with the theme). I want that image to be on EVERY page and post of my site. The problem is that in my recent post i put a featured image and that image replaced my header for that post. Im previous posts i have seted a featured image and this didnt happen. I dont know why now is changing my header image. Please help and thenks in advance!

    #18367
    Sakin
    Keymaster

    @osaczenitram: I don’t get it what you mean. Can you send me specific page URL where you have issue.

    #18389
    osaczenitram
    Member

    @Sakin: Yeah, no problem.

    As you can see here: http://www.eduardolaveglia.com/libros/libro-comunicacion-rentable-en-marketing/

    There when i set a featured image for the post, it becomes the header image.

    But in my other posts (and the thing that i wanto to happen) is that independently of the featured image, the header image stays the same, like in these two posts:
    http://www.eduardolaveglia.com/libros/el-desafio-de-escribir-un-libro-parte-2/
    http://www.eduardolaveglia.com/empresas/innovacion-uso-erroneo-palabra-fundamental/

    Both posts have featured images but the header image stays the same (the one with te book) and that is the header image that i want on eevery posts and page.

    #18398
    Sakin
    Keymaster

    @osaczenitram: Actually the Featured Header Image will be replaced by Featured Image on that particular page or post. I don’t know why it didn’t get replace for your other post. Please check in the Featured Image.

    If you want to add Logo image then that one is different. You need to add it from “Appearance => Theme Options => Header Options”.

    #18404
    osaczenitram
    Member

    @Sakin Thanks for your quick response. What i want is to have the header image not replaced when I add a featured image. Can it be done? Can it be coded to my child theme? I dont want the featured image of the post to appear on the header. I want the same image to appear always, the one that is here as header image: http://www.eduardolaveglia.com/construccion_de_marca/confianza-un-activo-en-riesgo/

    I understand that the logo appears over the header image, so i dont want a logo, my idea is having what i have as header in the link in all the pages and posts.

    #18405
    Sakin
    Keymaster

    Yes, you can build child theme and then create functions.php file in your child theme add the following Code in your child theme functions.php file.

    <?php
    /**
     * Header Image
     *
     * Uses Custom Header and Featued Images
     * @Hooked in catchevolution_headercontent
     * @since Catch Evolution 1.0
     */
    function catchevolution_featured_header() { 
    	global $wp_query, $post, $paged, $_wp_default_headers;
    	
    	// Header Image
    	$header_image_path = get_header_image();
    
    	if ( get_header_image() ) : ?>
    		<div id="header-image">
    			<img src="<?php header_image(); ?>" width="<?php echo get_custom_header()->width; ?>" height="<?php echo get_custom_header()->height; ?>" alt="" />
    		</div>
    	<?php endif; 
    	
    	
    }
    #18406
    osaczenitram
    Member

    @Sakin: Worked like a wonder!! Great work Sakin, you are great! Thanks for the support.

    #18407
    Sakin
    Keymaster

    @osaczenitram: Thanks for your appreciation.

Viewing 8 posts - 1 through 8 (of 8 total)
  • The topic ‘Featured image transforms into header image’ is closed to new replies.