http://jsfiddle.net/2aVKE/2/