I'm trying to find an efficient way for centering hyperlinked images in CSS. I wan this way to work with IE, firefox, and opera. I can easily use the <center> element, but XHTML 1.0 Strict doesn't support that.
Code:
.newspost img {
display:block;
margin-left:auto;
margin-right:auto;
border:0px;
text-align:center;
}
Right now that's what I use. The problem with that is that when I'm trying to put two or more images next to each other, the second image just moves onto the next line right underneath the first image. Is there a better way of doing this?