Forum Moderators: open
Also, I had a div without a width specified (it expands to fill the space between two fixed position divs) and noticed that in one case its content text extended beyond the width of the div. Other text wrapped fine. I fixed that problem with a width:100%. Unfortunately that nullified my margin-top:60px. This is in IE6. Anyone know what to make of it?
Thanks very much,
Ross
I want to center all the elements within a div. The only way I've found is to add the <center> tag in the html. Is there a 'better' way to accomplish this within CSS?
#your_div {
text-align: center;
}
or if it an image or element with a fixed width try:
#your_div {
margin-left: auto;
margin-right: auto;
}
Nick