how to make picture come middle css

Solutions on MaxInterview for how to make picture come middle css by the best coders in the world

showing results for - "how to make picture come middle css"
Lacie
27 Jan 2020
1<!DOCTYPE html>
2<html>
3  <head>
4    <title>Center an Image using text align center</title>
5    <style>
6      .img-container {
7        text-align: center;
8      }
9    </style>
10  </head>
11  <body>
12    <div class="img-container"> <!-- Block parent element -->
13      <img src="user.png" alt="John Doe">
14    </div>
15  </body>
16</html>