David Gonzalez David Gonzalez - 9 months ago 30
CSS Question

Bootstrap responsive fixed width col that is always centered

I am trying to make a login page that has a fixed width while having column in the center of the page. Something like page :


I have tried useing offset colms like this

<div class="col-md-4 col-md-offset-4" style=" float: none;
margin: 0 auto;">

Its not consistent size this way.


If it's a fixed-width DIV, you don't need Bootstrap's Grid. You just do:

<div style="width: 300px; margin: 0 auto;"></div>