How to center a <div> tag using CSS?

Code so far:

#master { position: absolute; height: auto; width: 1000px; min-height: 50px; } 

I want to center the tag horizontally, but not the task. What code do I need to add for this?

+4
source share
1 answer

Add the following rules to your CSS rules:

 margin: 0 auto; 

These will be the elements of the horizontal level of the central level.

+4
source

All Articles