Look at the javaEnabled() method of the navigator object.

For instance, to make a simple print-to-the page notification, place this script in the <body> of your page:

<script>
var jEnabled = navigator.javaEnabled();
if (jEnabled){
document.write("JAVA is enabled.")
}else{
document.write("JAVA is <i>NOT</i> enabled.")
}
</script>

Here is a working example:  JAVA is NOT enabled.

To redirect to a given page based on whether or not JAVA is enabled, try this in the <head> of your page:

<script>
var jEnabled = navigator.javaEnabled();
if (jEnabled){
window.location = "JAVA_page.html"
}else{
window.location = "non-JAVA_page.html"
}
</script>

Do remember, now — we're talking about JAVA (as in applets, for instance), here, not JavaScript.

Posted in: Java

Related FAQ's

Marius Ion ANGEL HOT SOFT LLC (800) 316-7677