I have tried searching for answers but nothing worked. I am trying to align a paragraph. I am pretty sure nothing is overwriting code in CSS. Here is the HTML and CSS:
body {
background-image: url("../../images/pic01.jpg");
background-repeat;
}
#main {
background-color: rgb(255, 84, 0);
width: 75%;
margin-left: auto;
margin-right: auto;
margin-bottom: auto;
margin-top: auto;
overflow: auto;
height: 100%;
color: rgb(255, 255, 255);
}
#center {
text-align: center;
}
<body id="top">
<div id="main">
<p id="center">
<h1> TEST </h1>
</p>
</div>
</body>
What is the mistake here?
` can't contain a `
`
– j08691 Dec 14 '16 at 18:39` elements are block level by default.
– j08691 Dec 14 '16 at 18:41TEST
` should be perfectly valid HTML since it is allowed to not explicitly close `` tags.
– connexo Dec 14 '16 at 19:06