var tF = {
addEvent: function(elm, evType, fn, useCapture) {
// cross-browser event handling for IE5+, NS6+ and Mozilla/Gecko
// By Scott Andrew
	if (elm.addEventListener) {
		elm.addEventListener(evType, fn, useCapture);
		return true;
	} else if (elm.attachEvent) {
		var r = elm.attachEvent('on' + evType, fn);
		return r;
	} else {
		elm['on' + evType] = fn;
	}
},

ascendDOM: function(e, target) {
// climb up the tree to the supplied tag.
	while (e.nodeName.toLowerCase() != target && e.nodeName.toLowerCase() != 'html')
		e = e.parentNode;
	return (e.nodeName.toLowerCase() == 'html') ? null : e;
},

nextprev: function(e) {
// show next/prev section of table
	var el;
	if (window.event && window.event.srcElement)
		el = window.event.srcElement;
	if (e && e.target)
		el = e.target;
	if (!el) return;
	var direc = el.firstChild.nodeValue.substr(0,4);
	if (direc=="Next") {
		tF.lastDisp = tF.lastDisp+7;
		if (tF.lastDisp > tF.nCols-1) tF.lastDisp = tF.nCols-1;
		tF.start = tF.firstDisp;
		tF.end = tF.lastDisp;
		tF.firstDisp = tF.lastDisp-49;
	} else {
		tF.firstDisp = tF.firstDisp-7;
		if (tF.firstDisp < 1) tF.firstDisp = 1;
		tF.start = tF.firstDisp;
		tF.end = tF.lastDisp;
		tF.lastDisp = tF.firstDisp+49;
	}
	for (var i=tF.start; i<tF.end+1; i++) {
		for (var j=0; j<tF.nRows; j++) {
			if (i<tF.firstDisp||i>tF.lastDisp) {
				tF.tab.rows[j].cells[i].style.display = "none";
			} else {
				tF.tab.rows[j].cells[i].style.display = "";
			}
		}
	}
	tF.showlinks();
},

showlinks: function() {
// show/hide parts of table footer
	if (tF.lastDisp == tF.nCols-1) {
		document.getElementById("nextlink").style.color = "#666666";
	} else {
		document.getElementById("nextlink").style.color = "#000000";
	}
	if (tF.firstDisp == 1) {
		document.getElementById("prevlink").style.color = "#666666";
	} else {
		document.getElementById("prevlink").style.color = "#000000";
	}
},

hiderow: function(e) {
// hide current row of table
	var el;
	if (window.event && window.event.srcElement)
		el = window.event.srcElement;
	if (e && e.target)
		el = e.target;
	if (!el) return;
	var thisrow = tF.ascendDOM(el, 'tr');
	if (thisrow) {
		thisrow.style.display = "none";
		document.getElementById("unhide").style.display = "";
	}
},

showrows: function() {
// unhide all rows of table
	if (!document.getElementsByTagName) return;
	var all_links = document.getElementsByTagName('a');
	for (var i = 0; i < all_links.length; i++) {
		if ((" " + all_links[i].className + " ").indexOf(" hide ") != -1) {
			var thisrow = tF.ascendDOM(all_links[i], 'tr');
			if (thisrow) thisrow.style.display = "";
		}
	}
	document.getElementById("unhide").style.display = "none";
},

addListeners: function() {
	if (!document.getElementsByTagName) return;
	var all_links = document.getElementsByTagName('a');
	for (var i = 0; i < all_links.length; i++) {
		if ((" " + all_links[i].className + " ").indexOf(" listtype ") != -1) {
			tF.addEvent(all_links[i], 'click', tF.nextprev, false);
		}
		if ((" " + all_links[i].className + " ").indexOf(" hide ") != -1) {
			tF.addEvent(all_links[i], 'click', tF.hiderow, false);
		}
		if ((" " + all_links[i].className + " ").indexOf(" unhide ") != -1) {
			tF.addEvent(all_links[i], 'click', tF.showrows, false);
		}
	}
	tF.tab = document.getElementById("tab");
	tF.nRows = tF.tab.rows.length;
	tF.nCols = tF.tab.rows[0].cells.length;
	for (var i = 0; i < tF.nRows; i++) {
		for (var j = 51; j < tF.nCols; j++) {
			tF.tab.rows[i].cells[j].style.display = "none";
		}
	}
	tF.showlinks();
	document.getElementById("unhide").style.display = "none";
	document.getElementById("unhide").style.color = "#000000";
},

firstDisp: 1,
lastDisp: 50
}
if (!Array.prototype.indexOf)
{
  Array.prototype.indexOf = function(elt /*, from*/)
  {
    var len = this.length;
    var from = Number(arguments[1]) || 0;
    from = (from < 0)
         ? Math.ceil(from)
         : Math.floor(from);
    if (from < 0)
      from += len;
    for (; from < len; from++)
    {
      if (from in this &&
          this[from] === elt)
        return from;
    }
    return -1;
  };
}
tF.addEvent(window, 'load', tF.addListeners, false);