HTML - Align a div tag to the center of the page
HTML - Align a div tag to the center of the page
CODE
<html>
<head>
<style>
.redCenteredStyle{
margin: auto;
top: 0;
right: 0;
bottom: 0;
left: 0;
position: absolute;
width: 100pt;
height: 100pt;
background-color: red;
}
</style>
</head>
<body>
<div class="redCenteredStyle"></div>
</body>
</html>
Comments
Post a Comment