How to check if browser supports Zoom css attribute? I know from Caniuse.com that only Firefoz does not support it, so from this question ( In Javascript, how to determine if my current Firefox browser is on the computer and not on everything else? ) I tried:
if ($.browser.mozilla) { ...
which returns me an error in chrome:
Cannot read property 'mozilla' of undefined
Another solution according to the answer detects if the browser supports this function, how can I do this?
Here's how you can find CSS function support in plain JavaScript. (Replace scaling with any function.)
document.createElement("detect").style.zoom === ""
, : jquery , css
- JS, CSS , , Modernizr.