navigator.taintEnabled()

JavaScript 1.1+ Nav3+ Syntax

navigator.taintEnabled()

Description

The taintEnabled() method of the navigator specifies whether data tainting is enabled.

Note

This method is removed in Navigator 4 and later releases.

Example

Listing 7.406 shows an example of how the taintEnabled() method is used.

Listing 7.406 Example of the taintEnabled() Method
<html>
<head>
<title> Example of the taintEnabled method of the navigator object</title>
</head>
<body>
							

<script language="JavaScript">
<!--Hide

// determine if tainting is enabled in the browser
if(navigator.taintEnabled()){
     document.write("Data tainting is enabled");
}
else{
     document.write("There is no data tainting");
}
// End Hide --->
</script>

</body>
							 </html> ...

Get Pure JavaScript now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.