1,105,395 Community Members

divs

Member Avatar
hwoarang69
Posting Pro
572 posts since Feb 2012
Reputation Points: -4 [?]
Q&As Helped to Solve: 0 [?]
Skill Endorsements: 9 [?]
 
0
 

i have a menu here. if i hover over it a sub menu drop down. but the problem is that the drop down menu display behind the div id = inner tag. i want to display front.

<div id = 'bottom_menu_wrapper'>
            <ul id='navbar'>
                <li><a href='#'>Apparel</a>
                    <ul>
                        <li><a href='#'>Female</a></li>
                        <li><a href='#'>Male</a></li>
                    </ul>
                </li>

                <li><a href='#'>Home Decor</a>
                    <ul>
                        <li><a href='#'>Furniture</a></li>
                        <li><a href='#'>Home Accessories</a></li>
                    </ul>
                </li>

                <li><a href='#'>Beauty</a>
                    <ul>
                        <li><a href='#'>Bath and Body</a></li>
                        <li><a href='#'>Hair Care</a></li>
                    </ul>
                </li>

                <li><a href='#'>Gourmet Food</a>
                    <ul>
                        <li><a href='#'>Specialty Items</a></li>
                        <li><a href='#'>Sweets</a></li>
                    </ul>
                </li>
        </div>



    <div id = 'bg_middle2'> 
        <div id = 'content'>
            <div id='inner'>
                <h1>randomstuff/h1> <img id="lock_img" src="#"/>
            </div>
        </div>
       </div>

if put div id=bottom_menu_wrapper at very end of my code than the sub menu display front of div id = inner tag. which is what i want.

is there a way to do same task without putting div id=bottom_menu_wrapper at end of my code? i dont want to switch code.

Member Avatar
<M/>
Industrious Poster
4,473 posts since Apr 2012
Reputation Points: 106 [?]
Q&As Helped to Solve: 139 [?]
Skill Endorsements: 114 [?]
Featured
 
1
 

This looks like the menu I solved for you not too long ago... unless i am wrong, I am probably reading the question wrong... Can you give me a better explanation of what you desire?

Member Avatar
JorgeM
IT Addict
6,394 posts since Dec 2011
Reputation Points: 581 [?]
Q&As Helped to Solve: 957 [?]
Skill Endorsements: 172 [?]
Moderator
Featured
Sponsor
 
1
 

You can use the z-index property to bring an element in front of another or behind another.

For example on one div assign a negative value for z-index and/or a positive value to the other div.

Member Avatar
hwoarang69
Posting Pro
572 posts since Feb 2012
Reputation Points: -4 [?]
Q&As Helped to Solve: 0 [?]
Skill Endorsements: 9 [?]
 
0
 

thanks. i didnt knew css has z-index

Question Answered as of 1 Year Ago by JorgeM and <M/>
Member Avatar
<M/>
Industrious Poster
4,473 posts since Apr 2012
Reputation Points: 106 [?]
Q&As Helped to Solve: 139 [?]
Skill Endorsements: 114 [?]
Featured
 
0
 

z-index, in my "vocab", is just layers... so becareful with them :)... I recommend you study them a bit more, they will become a pain in the rear later on... that's if you doing with a lot things on your page :)

You
This question has already been solved: Start a new discussion instead
Post:
Start New Discussion
Tags Related to this Article