So, instead of manipulating your code, I took a couple of steps back and rewrote something, trying to keep your overall structure in tact. What to do if instead of rotating css you wrote, we did something like a simple transform: rotate(-90deg); on the <div> with the text. Then slightly increase the height of the <td> tags.
HTML
<table border="2px"> <tr> <td> <div class="rotateText">ABC</div> </td> <td>123</td> <td> <div>ABCDEFGHIJ</div> </td> </tr> </table>
CSS
.rotateText{ -webkit-transform: rotate(-90deg); -moz-transform: rotate(-90deg); -ms-transform: rotate(-90deg); -o-transform: rotate(-90deg); transform: rotate(-90deg); } td{ height:100px; }
and finally JS JIDDLE
blubberbo
source share