automatically means automatic addition. The most common reason I use auto:
margin: 0 auto;
to center the element.
Please note: if the size is not announced, it will not work.
Example 1: div is not centered, auto does not work
<style> .cont { margin: 0 auto; } </style> <div class="cont"></div>
Example 2: a div is centered on a page
<style> .cont { width: 1000px; margin: 0 auto; } </style> <div class="cont"></div>
user1558952 Mar 21 '13 at 0:19 2013-03-21 00:19
source share