Skip to content Skip to sidebar Skip to footer

Div Not Showing Above Text Box

I want to show a search icon over the start of the a text input box. Currently my code looks like this:

Solution 1:

You can solve it using relative position for both. But just change their z-index.

#search-icon {

background-color:#455a21;
height:60px;
width:60px;
border:thin solid black;
border-radius:30px;
z-index:100;
position: absolute;
z-index: 2;
}

input#search {
position:absolute;
top:15px;
left:30px;
padding:10px;
padding-left:35px;
border-radius:20px;
border:thin solid #6d6e71;
z-index:1;}​

is this what you are looking for here

Solution 2:

I dont know what you want exactly but check it out this one http://jsfiddle.net/V8AZE/

Post a Comment for "Div Not Showing Above Text Box"