Text rotation for all

In: web resources

29 Jul 2009

Jonathan Snook has posted a nice nugget on text rotation with CSS that takes a nice bit of markup like this:

HTML:

  1.  
  2. <div class=“example-date”>
  3.   <span class=“day”>31</span>
  4.   <span class=“month”>July</span>
  5.   <span class=“year”>2009</span>
  6. </div>
  7.  

and converts it to:

all via the CSS:

CSS:

  1.  
  2. -webkit-transform: rotate(-90deg);
  3. -moz-transform: rotate(-90deg);
  4. filter: progid:DXImageTransform.Microsoft.BasicImage(rotation=3);
  5.  

Yup, even IE.

Comment Form

About this blog

This blog delivers stylish and dynamic news for designers and web-developers on all subjects of design, ranging from: CSS, Ajax, Javascript, web design, graphics, typography, advertising & much more. Our goal is to help you communicate effectively on the web with an engaging website or functional interface.