JavaScript NPAPI Support Detection

How can you determine if the browser supports NPAPI from JavaScript? Not all of them do, and although I can rely on a user agent, I would rather do it in a more reliable way if it exists.

Unfortunately, I cannot simply determine if my plug-in is loaded or not, as it may be that the plug-in is simply not yet installed in a supported browser.

Thanks.

+4
source share
2 answers

There is no JS API for this, but basically all desktop browsers, except for IE- / Trident-based, and ChromeOS support NPAPI.

You can find out if your plugin is installed by installing navigator.plugins .

+1
source

If you want to check if java plugins are enabled in the browser, you should use navigator.javaEnabled() . He will work in chrome.

-2
source

All Articles