I'm working on a game website and want to place two divs inside a 'header' div such that they are horizontally aligned and to the left and right of this container div. See below for an example:
Oli Matt
Here is my attempt. What is my error?
HTML:
<div class="header">
<div class="playerOne">
Oli
</div>
<div class="playerTwo">
Matt
</div>
</div>
CSS:
.header{
display: inline-block;
}
.playerOne{
margin-left: 0;
}
.playerTwo{
margin-right: 0;
}