Rotate the <div> element 45 degrees. - HTML CSS CSS

HTML CSS examples for CSS:Quiz

Description

Rotate the <div> element 45 degrees.

Demo Code

ResultView the demo in separate window

<!DOCTYPE html>
<html>
<head>
<style>
div {<!-- ww  w. j a va 2  s  .  c  o  m-->
    width: 100px;
    height: 100px;
    margin: 50px;
    background-color: pink;
    border: 1px solid black;
    transform: rotate(45deg);
}

</style>
</head>
<body>

<div></div>

</body>
</html>

Related Tutorials