function checkSupport(prop) { var div = document.createElement('div'), pref = 'Khtml Ms O Moz Webkit'.split(' '), len = pref.length; return (function(prop) { if(prop in div.style) return prop; prop = prop.replace(/^[a-z]/, function(val){ return val.toUpperCase(); }); while(len--){ if(pref[len] + prop in div.style ){ return pref[len] + prop; } } return false; })(prop); }