/

HTML / CSS / JavaScript Tutorial

JavaScript Window property: status

[this page | pdf | back links]

The status property (of the JavaScript BOM window object) sets / returns the text in the window status bar.

 

Setting the status property typically does not work with many major browsers (as it introduces scope for impersonation of sites). To allow scripts to change the status text, the user must typically alter the configuration settings of the browser.

 

EXAMPLE:


HTML USED IN THIS EXAMPLE:
<!DOCTYPE html>
<html> <!-- Copyright (c) Nematrian Limited 2018 -->
<head></head>
<body>
Window default default status: <b id="element"></b><br>

<script>
window.status = "Hello";
var x = window.status;
document.getElementById("element").innerHTML = x;
</script>

</body>
</html>


NAVIGATION LINKS
Contents | Prev | Next | JavaScript DOM (and BOM)


Desktop view | Switch to Mobile