Search code examples
htmlcssslidernivo-slider

CSS Overridden: Why Doesn't Search Box Float right?


I'm at a total loss on why I can't align the Search box to the left

The Search and RSS feed align on the test page:

http://scottjaxon.com/devsite/testnivo48.html

As it is on the home page (with a pic instead of nivo slider) http://scottjaxon.com/devsite/index.html

I don't get it. I gotta be missing the smallest thing!

#wrapper #user1 #feahome #searchhome {
float: right;
color: #FFFFFF;
height: 22px;
margin-top: 8px;
padding: 0px 20px 0px 20px;

Or is it something with the NivoSlider CSS?

.nivoSlider {
position:relative;
width:100%;
height:auto;
overflow: hidden;
}
.nivoSlider img {
position:absolute;
top:0px;
left:0px;
}
.nivo-main-image {
display: block !important;
position: relative !important; 
width: 100% !important;
}

Solution

  • Your index.html and testnivo48.html have different dom structures.

    In index.html, the feahome div tag is the parent of rsshome and searchhome div tags; but in the testnivo48.html, they are all on the same level.

    That's why the following css rule (in http://scottjaxon.com/devsite/css/style.css) gets applied on index.html, but ignored in testnivo48.html

    #wrapper #user1 #feahome #searchhome {
        ...
    }
    

    After you fix the html, your problem might get solved.