tags:

views:

25

answers:

3

I have php generating html and I want to create layers. Basically I want to have a menu overlay without messing up the structure of everything displayed under it.

A: 

You need to use CSS keyword z-index. More information and complete tutorial here:
http://www.html.net/tutorials/css/lesson15.asp

shamittomar
A: 

In your CSS file -

#overlaymenu {
    z-index: 1000;
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    height: 20px;
    background: #000;
    color: #FFF;
}

In your HTML -

<div id="overlaymenu">My menu's content!</div>

Hope that helps!

Raphael Caixeta
A: 

Try this:

CSS:

#menuOverlay {
   position:fixed; /*or  absolute*/
   top:0;
   left:0;
   width:100%:
   height:30px;
   background:green;
   z-index: 999; /* or  greater value */
}

HTML:

<div id="menuOverlay">
   menu items here ....
</div>
jerjer
Thanks! worked very well
tylercomp