Need help? Check out our Support site, then

chateau theme: how to link header image with homepage

  1. Hi, I'm trying to link my header image in the chateau theme to the homepage and just can't figure out where exactly I have to change the header.php

    Here's what my header.php currently looks like:

    <!-- HEADER -->
    <div id="header">
    <div id="menu">
    <?php wp_nav_menu( array( 'theme_location' => 'mainmenu', 'container' => '', 'depth' => '2') ); ?>
    <div id="mainTitle">
    /" title="« Return to <?php bloginfo('name'); ?>'s Homepage">
    <?php bloginfo('name'); ?> <span>~ <?php bloginfo('description'); ?></span>

    <div id="search">
    <?php get_search_form(); ?>
    <div id="mainImage">
    if (!is_404() && !is_attachment()) {
    if (is_singular() && has_post_thumbnail($post->ID) && ($image = wp_get_attachment_image_src( get_post_thumbnail_id($post->ID), 'post-thumbnail') ) && $image[1] >= HEADER_IMAGE_WIDTH) :
    echo get_the_post_thumbnail( $post->ID, 'post-thumbnail' );
    else : ?>
    <img src="<?php header_image(); ?>" width="<?php echo HEADER_IMAGE_WIDTH; ?>" height="<?php echo HEADER_IMAGE_HEIGHT; ?>" alt="<?php bloginfo('name'); ?>" title="<?php bloginfo('name'); ?>" />
    <?php endif; } ?>

    Sorry for the messy layout, hope it is still readable!

    Can anybody help me?
    Thanks, Melanie

    PS: It's for a blog I'm currently setting up.

  2. You did not specify a blog address or reason for posting when you created this topic.

    This support forum is for blogs hosted at If your question is about a self-hosted WordPress blog then you'll find help at the forums.

    If you don't understand the difference between and, you may find this information helpful.

    If you forgot to include a link to your blog, you can reply and include it below. It'll help people to answer your question.

    This is an automated message.

  3. The header image for the Chateau theme at is linked by default. See for an example.

    You can see the code for the version of the theme here in case that's helpful:

    Head over to if you have further questions about a setup.

Topic Closed

This topic has been closed to new replies.

About this Topic