0

How to center horizontally a div element

works in IE8

<div id="outer">
  <div id="inner">Foo foo</div>
</div>
#inner {
  display: table;
  margin: 0 auto;
  border: 1px solid black;
}

#outer {
  border: 1px solid red;
  width:100%
}
RUN
add comment
Suggest a different solution or add another example