0
how do i make my headings or text be centered?
1 Answer
+ 1
<html>
<head>
<title>Page Title</title>
<style>
h1 {
text-align: center;
}
p {
text-align: center;
}
section {
width: 100px;
height: 100px;
background-color: green;
margin: 10 auto;
}
</style>
</head>
<body>
<h1>Centered Heading</h1>
<p>Centered Paragraph</p>
<section><p>Horizontally Centered Div</p></section>
</body>
</html>