Rather than featuring the current incomplete feature detection code refer to the always up-to-date and complete Modernizr feature detect