
// Commonly-used functions, reduced.

function d(s) {return document.getElementById(s);}
function dE(o,s) {return o.getElementsByTagName(s);}

/**
 * toggleDisplay()
 *
 * Will toggle the display property of the style object for any
 * DOM element or object that supports style as a property.
 *
 * Warning: This'll wreak havoc if applied to <TR> elements. Those
 * babies got different types "table-row" | "block" dependant on
 * what browser's being used.
 *
 * Warning: Written in Texas.  Yeehaw.
 *
 * Typical usage:
 * toggleDisplay(document.getElementById("foo"));
 */
function toggleDisplay(o)
{
  n = o.nodeName.toLowerCase();
  t = (
        n == "span"
        || n == "img"
        || n == "a"
      ) ? "inline" : "block";

  if (o.style)
      o.style.display =
        (o.style.display == t) ? "none" : t;
}

