Site logo

Archived topic

Add slider behind the header logo

16 replies · Started by Nirvana Tours SA on August 23, 2016

Viewing posts 1–15 of 17

Hi Tom

How do I float my header logo over a slider?

I have placed a slider in the header area, but my site logo remains bellow the slider - I would like it to float over the slider.

You could use the Page Header add-on.

In "Advanced Settings", choose to merge the header, and enable the "Place content behind header" option.

Hi Tom

Sorry, but I'm very new to this - where do I find "Advanced Settings" - I've looked everywhere I can think of.

Hi Tom

I don't have that tab in my Page Header Metabox.
It was there for a second but then disappeared again.
I only have Image/Content/Logo settings.

I'm using GP ver 1.3.39

I also just realized that this is for a page header.
I would like this to be for the site header that will appear on all my pages.

Ah I understand.

It's not easy to do I'm afraid.

You could try adding something like this into the "Before Header Content" hook:

<div class="fixed-slider-background">
    Your slider shortcode in here
</div>

Then add this CSS:

.fixed-slider-background {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.site-branding,
.site-logo,
.header-widget {
    z-index: 2;
    position: relative;
}

.site-header {
    overflow: hidden;
}

.metaslider .theme-default .nivoSlider,
.metaslider .theme-default .nivoSlider img {
    height: 100%;
}

Untested, but should be a decent start.

Thanks Tom

That code worked, but the only thing now is that the logo and menu bar is stuck behind the slider images.
I tried changing the z-index values, but this puts the slider either all the way back behind the header background.

Any ideas?

Any chance you can show me?

Hi Tom

Website is http://www.nirvanatourssa.com

If you need access to the wordpress editor just let me know where I can email a temporary login details for you.

Regards
Geordie

Ah, try adding it into the Before Header Content hook instead of the Before Header hook.

Still no change when placing it in "Before Header Content" hook.
Also, it doesn't resize correctly when viewing in tablet or mobile mode.
The slider doesn't seem to be actually replacing the header background, but rather floating on top of it - if that makes any sense to you.

Aah Tom, a big ups to you man.
That works just fine.
I'll have to buy you a coffee when payday rolls by next.
Thanks for all your assistance - and patience.
Geordie

You're welcome, I'm glad I could help :)

This archived topic is closed to new replies.