• How to horizontally center a div?

    by  • August 23, 2019 • Blog

    HTML is a quite simple way to build a website but sometimes it will take us a lot of time because of very simple problem. This article will help us solve the problem how to horizontally center a <div> tag in HTML page.

    Let’s consider we have a HTML tag like this

    Now, it’s time to do the magic to make center the tag div “inner”

    This solution work for IE8+ too. Of course it work well on Chrome and Firefox.

    If you run the above html on web browser you will see the result like this

    Run your own and enjoy. Welcome any comment 🙂