CSS Transform: Rotate

By Xah Lee. Date: . Last updated: .




something in the water

here's the HTML code:

<div class="t17362">something in the water</div>

here's the CSS:

div.t17362 {
border:solid thin red;
width: 30ex;
transform:rotate(-5deg);
}

as of , this works in Firefox, Opera, all on Linux.

for Google Chrome and Safari, you might add this:

-webkit-transform: rotate(-5deg);

Reference

http://www.w3.org/TR/css3-transforms/

Like what you read? Buy JavaScript in Depth
or, buy something from my keyboard store