function setStylesheet () {
	selectCSS = document.createElement('link');
	selectCSS.setAttribute('type','text/css');
	selectCSS.setAttribute('rel','stylesheet');
	selectCSS.setAttribute('media','screen');
	selectCSS.setAttribute('href','static/css/js.css');
	document.getElementsByTagName('head')[0].appendChild(selectCSS);
}
function openPrint() {
            var str = window.location.href;
            var temp = str.length;
            var pos = str.indexOf('?');
            if (pos >= 0) {
                str = str + "&print=true";
            } else {
            str = str + "?print=true";
            }
            window.open(str, this.target, "width=600,height=800,resizable=yes,menubar=yes,scrollbars=yes");
}

// function to check links for href="#do_popup" and replace it with 
// href="#" id="show1" thus enabling popup functionality
function enablePopups() {
   var list_a = document.getElementsByTagName('a');

   for ( var i = 0; i < list_a.length; i++  ) {
      if ( list_a[i].href.indexOf('#do_popup') >= 0 ) {

	list_a[i].href = '#';
	list_a[i].setAttribute('id','show1');

		YAHOO.namespace("example.container");		
		YAHOO.example.container.overlay1 = new YAHOO.widget.Overlay("overlay1", {
			fixedcenter:true,
			visible:false,
			width:"662px"
			}); 

		YAHOO.example.container.overlay1.render();		
		YAHOO.util.Dom.addClass(document.getElementById("overlay1"), 'not-now');
		YAHOO.util.Event.addListener("show1", "click", showLayover, YAHOO.example.container.overlay1, true); 
		YAHOO.util.Event.addListener("hide1", "click", hideLayover, YAHOO.example.container.overlay1, true);

      break;
  }
}
}
				
		// functions needed for layover only
				
	showLayover = function() {
		YAHOO.util.Dom.removeClass(document.getElementById("overlay1"), 'not-now');
		YAHOO.util.Dom.removeClass(document.getElementById("masked"), 'not-now');
		YAHOO.example.container.overlay1.show();
		}

	hideLayover = function() {
		YAHOO.util.Dom.addClass(document.getElementById("masked"), 'not-now');
		YAHOO.example.container.overlay1.hide();
		}
				
function nogo () {
return false;
}
