.container{
display:bock;
width:fit-content;
margin:auto;
}
// add to the parent element
.parent {
display: grid;
place-items: center;
}
body{
display: grid;
place-items: center;
}
.element {
position: absoloute;
margin: auto;
left: 0;
right: 0;
top: 0;
bottom: 0;
}
element {display: block; float: left; vertical-align: middle; text-align: center}
<style>
#para {
margin-left: auto;
margin-right: auto;
width: 8em
}
</style>
<P id="para">This is a paragraph </p>
.element {
margin: auto;
}
Code Example |
---|
Css :: beige hex code |
Css :: css noselect |
Css :: hide scroll bar |
Css :: scroll tbody fixed thead |
Css :: ovale css |
Css :: css style media does not found cshtml |
Css :: horizontally align button |
Css :: gradient over image css |
Css :: css placeholder text truncate |
Css :: css blur background behind div |
Css :: border around img css |
Css :: css background full screen |
Css :: Install Node Sass/Scss |
Css :: mysqli check if delete was successful |
Css :: blue color when button click web mobile |
Css :: space between li css |
Css :: nth-child() css |
Css :: css hiddden |
Css :: left and right box shadow only |
Css :: break word css |
Css :: padding shorthand |
Css :: comentarios en css |
Css :: how to add fade-in with page transition |
Css :: grid columns |
Css :: how to change height font css |
Css :: css how to make a pre tag to break line |
Css :: sass watch in all your project automatically |
Css :: how to style submit button css |
Css :: css animation properties |
Css :: bash list all npm processes |