Max Headroom
05-07-2005, 10:44 AM
How do I center an image that is using the 'background-image:' element of CSS? I have tried this:
.title {
text-align:center;
margin-top:0px;
margin-bottom:0px;
padding:0px;
width: 554px;
height: 83px;
background-image: url(./images/title.png);
}
and this:
.title {
text-align:center;
display:block;
width: 554px;
height: 83px;
background-image: url(./images/title.png);
}
But neither of them work. They all just align to the left. Thanks for any help.
.title {
text-align:center;
margin-top:0px;
margin-bottom:0px;
padding:0px;
width: 554px;
height: 83px;
background-image: url(./images/title.png);
}
and this:
.title {
text-align:center;
display:block;
width: 554px;
height: 83px;
background-image: url(./images/title.png);
}
But neither of them work. They all just align to the left. Thanks for any help.