Why can't you use numbers in CSS and is there another way of doing the job? I have the following code:
<div class="center 400-width" id="position">
<div class="" id="header">
Header
</div>
<div class="" id="content">
Content
</div>
<div class="" id="footer">
Footer
</div>
</div>
The CSS selects the class 400-width
which means the container gets a width of 400px
. And the background-color
is for checking if it's true.
.400-width{
width:400px;
background-color:blue;
color:white;
}
It doesn't happen right now as you can see here
I solved the problem by replacing 400-
by four
. So it becomes fourwidth
.