Table with 'auto-sizing' columns

What I want

A table with multiple columns. The text in each column may be longer than the width of a particular column, and I want the text to truncate as appropriate. Possible solutions:

  1. Trim the text strings server side
  2. Trim the text strings client side with JS
  3. Use some CSS to try and make it work automatically

CSS Examples

Below are some examples I tried out using div sections and CSS. I tested each one on:

table

Thanks to Bruno Fassino for this solution which works in IE, Moz and O7. I've removed all my previous non-working solutions now.

some medium length text some other text asdgfjh alsdkfjh asldkjfh alskdjfh alskdjfh dasklfjghaweliurfgha ldfkjhgas
  asdgfjh alsdkfjh asldkjfh alskdjfh alskdjfh dasklfjghaweliurfgha ldfkjhgas asdgfjh alsdkfjh asldkjfh alskdjfh alskdjfh dasklfjghaweliurfgha ldfkjhgas