Site logo

Archived topic

no header image on home

6 replies · Started by Hans on August 20, 2016

Viewing posts 1–7 of 7

Hi Tom,

I moved my homepage from localhost to domainserver manually. I want to have a full width background on homepage while nearly all other pages have the same header image. I solved it on local host but I do not remember how I did it.

In hook wp_head I use php:

<meta name="specificfeeds-verification-code" content="ADNMEsxTAk3PnBgDNVfz"/>
<?php if ( is_home() ) : ?>
<img src='wp-content/uploads/bgimage/rotate.php' id='ktgbild' alt=''>
<?php endif; ?>

CSS is as follows

#ktgbild {
  	position: fixed; 
  	top: 0; 
  	left: 0; 
	/* Preserve aspet ratio */
	min-width: 100%;
  	min-height: 100%;
        z-index: -1;
}

The header background is introduced by Appearance, Backgrund Image, Header Area (my Admin is in German - mught be that the name are different).

How can I solve the problem???

Hi there,

First, wp_head is for scripts only - no HTML. You want to add the HTML into the Before Header hook.

Then, instead of this: wp-content/uploads/bgimage/rotate.php

You need to add the full URL: http://yoursite.com/wp-content/uploads/bgimage/rotate.php

That should get you closer :)

Hi Tom,

I followed your advice. But nothing changed. To understand what I mean here is the URL

http://huppenbroich.de/spd-roetgen/

On home page you see the overlay of the header on top of the full page. I managed somehow to let it disappear. But unfortunately I do not remember. I appreciate your advice.

I'm not sure what you mean?

I'm seeing a header with a background image set - all looks normal?

Maybe something like this will work:

.home .site-header {
    background: transparent;
}

Hi Tom,

it works perfectly --- many thanks.

You're welcome :)

This archived topic is closed to new replies.