Perfect Centering using HTML/CSS
Here It's a post about how you can Center an HTML element with CSS style.
- To horizontally center a block element (like <div>), use
- To just center the text inside an element, use
- To center an image, set left and right margin to
autoand make it into a
And for centering horizontally and vertically you can use my code where i have used Flex ( The Flexible Box Layout Module, makes it easier to design flexible responsive layout structure without using float or positioning.).
To know more about what is flex and how it is use visit W3 Flex.
Hope this will help you <3