Rotate the DIV side using CSS3 transform

I have a menu that should appear at a side-turn of -90 degrees, as shown below.

enter image description here

NOTE. Div has dynamic width so we cannot rotate it and then move it left or up using top:-XX .

 #rotateme { -webkit-transform: rotate(-90deg); -webkit-transform-origin: 0 0; position: absolute; top: 250px; /*not going to work with dynamic width */ left: 0px; } 

I tried a lot of CSS3 transformation and the beginning of the transformation, but no combination could force me there.

Here I created a fiddle ( http://jsfiddle.net/P2UQy/8/ ), which creates the contents of a div randomly (dynamic width). This script also includes an attempt to crash rotate using CSS3 transform.

Can someone make it work as shown in the picture above? Feel free to add additional containers / wrappers if necessary.

+4
source share
1 answer

I updated the script . Hope it works.

+4
source

All Articles