HTML How to Make a Website CSS: Cascading Style Sheets Center the Wrapper

Vladimir Kozak
Vladimir Kozak
6,314 Points

Wrapper id not working?

I have attempted to use a wrapper id to center the surrounded elements but whenever I open up the webpage everything is still aligned on the left hand side. Apparently the div tag is not showing up in this pasting of my code. Imagine it being right before header and after the closing footer tag, and encapsulating all that code.

Liam Clarke
Liam Clarke
9,872 Points

ideally i need more information than this since your not stating what method your using, so im just going to show you the way i do it.

In your CSS write this

/* This represents the wrapper */
.wrapper {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    justify-content: space-between;

/* This represents multiple DIRECT children of the wrapper */
.wrapper-item {
    width: 10em;
    height: 10em;
    text-align: center;
    background: lightgrey;
Kathryn Notson
Kathryn Notson
25,594 Points

Valdimir Kozak:

Show your code following the instructions for Markdown Cheatsheet.