CSS image centering not working
Permalink
I am trying to center the sitewide logo header, and the margin setting to center it is not work. Everything else is changing properly. What am I missing?
<style type="text/css">
IMG.displayed {
display: block;
padding:0;
width: 900px;
height: 150px;
margin-top: -25;
margin-left: auto;
margin-right: auto;
z-index: 100;
position: fixed;
background-color: #FFFFFF;
}
</style>
<IMG class="displayed" src="http://bpbuild.concrete5.arvixe.com/files/6313/7156/5959/Logo.png"/>
P.S. I am also trying to eliminate the margin/padding when published that occurs at the top of the page, in order to hide overflow completely.
<style type="text/css">
IMG.displayed {
display: block;
padding:0;
width: 900px;
height: 150px;
margin-top: -25;
margin-left: auto;
margin-right: auto;
z-index: 100;
position: fixed;
background-color: #FFFFFF;
}
</style>
<IMG class="displayed" src="http://bpbuild.concrete5.arvixe.com/files/6313/7156/5959/Logo.png"/>
P.S. I am also trying to eliminate the margin/padding when published that occurs at the top of the page, in order to hide overflow completely.
Is this site still from ur previous build? If yes, your image has a position fix. delete that, than it will centre as it should (tested on my pc with firebug on ur site).
Best to wrap your image with an id/class and position it fixed if you want to display like what you are trying too.
Hope it helped.