/*function setActiveStyleSheet(title) {
var i, a, main;
for(i=0; (a = document.getElementsByTagName("link")[i]); i++) {
  if(a.getAttribute("rel").indexOf("style") != -1) {
	a.disabled = true;
	if(a.getAttribute("title") == title) a.disabled = false;
  }
}
}
setActiveStyleSheet("medium");*/
      
function printArticle(id)
{
	if (id != null) {
		window.open('print.php?id='+id,'s','toolbar=no,scrollbars=yes,height=600,width=850, left=20, top=20');
	}
}

function emailFriend() {
  if ($('emailaFriend').style.display == 'none')
    $('emailaFriend').show();
  else
    $('emailaFriend').hide();
  return false;
}

function sendEmail() {
  new Ajax.Updater("information", "/PHP/emailSend.php", {method: 'post',
                                                         parameters: $('emailaFriendForm').serialize()});
}

// JavaScript Document
sfHover = function() {
	var sfEls = document.getElementById("home-links").getElementsByTagName("li");
	for (var i=0; i<sfEls.length; i++) {
		sfEls[i].onmouseover=function() {
			this.className+=" sfhover";
		}
		sfEls[i].onmouseout=function() {
			this.className=this.className.replace(new RegExp(" sfhover\\b"), "");
		}
	}
}
if (window.attachEvent) window.attachEvent("onload", sfHover);

function getDate() {
// Get today's current date.
var now = new Date();

// Array list of days.
var days = new Array('Sunday','Monday','Tuesday','Wednesday','Thursday','Friday','Saturday');

// Array list of months.
var months = new Array('January','February','March','April','May','June','July','August','September','October','November','December');

// Calculate the number of the current day in the week.
var date = ((now.getDate()<10) ? "0" : "")+ now.getDate();

// Calculate four digit year.
function fourdigits(number)	{
	return (number < 1000) ? number + 1900 : number;
								}

// Join it all together
today =  days[now.getDay()] + ", " +
         months[now.getMonth()] + " " +
         date + ", " +
         (fourdigits(now.getYear())) ;

// Print out the data.

document.write(today);
}
