/* deals with the lack of target=_blank in Strict doctype */

function externalLinks() {
	if (!document.getElementsByTagName) return;
	var anchors = document.getElementsByTagName("a");
	for (var i=0; i<anchors.length; i++) {
		var anchor = anchors[i];
		if (anchor.getAttribute("href") &&
		anchor.getAttribute("class") == "target_blank")
		anchor.target = "_blank";
	}
}
window.onload = externalLinks;

// prevent problems when Firbug not installed
if (typeof console == "undefined") var console = { log: function() {},
  debug: function() {},
  info: function() {},
  warn: function() {},
  error: function() {},
  assert: function() {},
  dir: function() {},
  dirxml: function() {},
  trace: function() {},
  group: function() {},
  groupEnd: function() {},
  time: function() {},
  timeEnd: function() {},
  profile: function() {},
  profileEnd: function() {},
  count: function() {}
}; 

/* deals with 'blind' menu items: that have children but not a page to show */

$(document).ready(function(){
	x=$("ul.menu a").add("div.breadcrumb a").filter("[title^='link_off_']").each(
			function(i) {
				$(this).replaceWith("<span class='link_off'>" + $(this).text() + "</span>");
			}
		);
	
	

});

// prevent problems when Firbug not installed
if (typeof console == "undefined") var console = { log: function() {},
  debug: function() {},
  info: function() {},
  warn: function() {},
  error: function() {},
  assert: function() {},
  dir: function() {},
  dirxml: function() {},
  trace: function() {},
  group: function() {},
  groupEnd: function() {},
  time: function() {},
  timeEnd: function() {},
  profile: function() {},
  profileEnd: function() {},
  count: function() {}
}; 