I am new to css. I'm actually trying to display three divs on the same line, with one element to the left of the page, the second element in the middle of the page and the third element on the right side of the page. Here is my script
<!DOCTYPE html>
<meta charset="utf-8">
<style>
#name {
color: black;
display: inline;
}
#group {
color: black;
display: inline;
float: right;
}
#cent {
color: black;
display: inline;
}
</style>
<div id="name" style="color: #000000;">EXAMPLE</div>
<div id="group" style="color: #000000;">GROUP</div>
<div id="cent">TEST</div>
Here the conclusion should be
EXAMPLE TEST GROUP
but the output is displayed in
EXAMPLE TEST GROUP
Can anybody help me, fix this .TIA
source
share