CSS Center Alignment

 22 Apr 2020  Snippets

CSS Center Alignment

Basic alignment for elements with relative display:

/* Align a DIV element */

.divcenter {
  margin: auto;

/* Align an IMG element */

.imgcenter {
  display: block;
  margin-left: auto;
  margin-right: auto;
Webmentions & Comments

Copyright © Paramdeo Singh. Built with Jekyll and ☕️ in Guyana. All Rights Reserved.

Last Site Build on Thu, 21 Oct 2021 17:49:44 -0400

1MB Club Badge

Paramdeo Singh Guyana

Riding the wave of consciousness in this treacherous mortal sea.

Technology Design Strategy Literature Personal Blogs