spacer
Yehuda Shiran November 11, 1999
Using the Status Bar
Tips: November 1999

Yehuda Shiran, Ph.D.
Doc JavaScript

Developer News
Microsoft Shows Off Silverlight 4, IE9 Plans
Metasploit Expands Vulnerability Test Framework
HyperCard Reborn?

At the bottom of the browser window is a status bar. Part of that bar includes a text field that normally discloses the document loading progress of the URL of alink that the mouse is pointing to at any given instant. You can control the temporary content of that text field by assigning a text string to the window object's status property. In multi-frame environments, you can set the window.status property without having to worry about referencing the individual frame. The status property is commonly used to explain the nature of the destination of a link in response to the onMouseOver event:

<SCRIPT LANGUAGE="JavaScript">
<!--

function display(str) {
  window.status = str;
  return true;
}

// -->
</SCRIPT>
<A HREF="http://www.docjs.com/"
   onMouseOver="return display('Free JavaScript columns, tips, and scripts.')"
   onMouseOut="return display('')">Doc JavaScript</A>

Here's the live example: Doc JavaScript. Note that the status property is supported by all JavaScript-enabled browsers. Also notice that the event handler must return true. This statement is required or the status message will not display.


People who read this tip also read these tips:

Look for similar tips by subject:

internet.commediabistro.comJusttechjobs.comGraphics.com

Search:

WebMediaBrands Corporate Info

Legal Notices, Licensing, Permissions, Privacy Policy.
Advertise | Newsletters | Shopping | E-mail Offers | Freelance Jobs

webref The latest from WebReference.com Browse >
Rolling Out Your Own HTML Application Version Control · HTML 5: Client-side Storage · Working with Ajax Server Extensions
Sitemap · Experts · Tools · Services · Email a Colleague · Contact FREE Newsletters 
 The latest from internet.com
Wi-Fi Product Watch, November 2009 · Chip Market Recovering From '08 Collapse · Low-Cost Tools to Kickstart Your New Business