Page 1 of 1

Div container with background image

Posted: Sun Jan 26, 2014 11:18 am
by alainjanquart
Hello,

I have a div container in my template.
There I put my navigation menu in it.
I want to display a background image in that container.
But the image is showing under the menu. And I want it behind the menu.
So that it looks like the menu is in the image.

I tried to nest a second container in my first one, but that does not work.

Any idea how i can do that?

Thanks in advance

Lainkes

Re: Div container with background image

Posted: Sun Jan 26, 2014 11:22 am
by Webdongle
Give the css for the div's class/id a z-index minus value http://www.w3schools.com/cssref/pr_pos_z-index.asp ???

Re: Div container with background image

Posted: Sun Jan 26, 2014 11:43 am
by alainjanquart
This is my css code :

Code: Select all

#navigation{
	background: #e2e7d3 url(../images/navigation.png) no-repeat 15px 189px;
	z-index:-1;
	position: absolute;
	left: 10px;
	width: 200px;
	height: 380px;
	border: 1px solid #F60;
	color: #999;
	text-align: left;
	top: 175px;
}
i guess I'm doing something wrong here.

Thanks for feedback

Lainkes

Re: Div container with background image

Posted: Sun Jan 26, 2014 1:25 pm
by Per Yngve Berg
Do you have a link to the page?

You are displacing the background image by 15px 189px.

Re: Div container with background image

Posted: Sun Jan 26, 2014 4:17 pm
by alainjanquart
I found the solution in the meantime by experementing a bit.

Thanks for the tips.

Lainkes

Re: Div container with background image

Posted: Mon May 08, 2017 10:32 am
by Reditron1
I am also currently experiencing this problem which is driving me nuts! \

any idea how I can change the background image... my current template is mx_joofree12.

url: http://reditron.co.za/

Thanks