Home Articles FAQs XREF Games Software Instant Books About Feedback Search Site-Map
irt.org logo

Q252 How can I safely detect whether the browser has Java enabled?

irt.org | Knowledge Base | JavaScript | Java | Q252 [ previous next ]

Q252 How can I safely detect whether the browser has Java enabled?

<script language="JavaScript"><!--
if (navigator.appName == 'Microsoft Internet Explorer' && navigator.appVersionindexOf('MSIE 3'))
    var java = false;
else
    var java = navigator.javaEnabled();
//--></script>

Now you have a boolean variable that you can use throughout the rest of your page.

Feedback on 'Q252 How can I safely detect whether the browser has Java enabled?'


Provide feedback ...
AddThis Social Bookmark Button

Provide feedback ... AddThis Social Bookmark Button


Last Updated: 30th March 2008. Maintained by: Martin Webb and Michel Plungjan
irt.org liability, trademark, document use, privacy statement and software licensing rules apply.
Copyright © 1996-2008 irt.org, All Rights Reserved.