/**
 * Open exernal links in new window
 */
function externalLinks() {
	if (!document.getElementsByTagName) return;
 
	var anchors = document.getElementsByTagName("a");
	for (var i=0; i<anchors.length; i++) 
 	{
 		var anchor = anchors[i];
   		var attr = String(anchor.getAttribute("rel"));
   		if (anchor.getAttribute("href") && attr.toLowerCase().match("external"))
    		anchor.target = "_blank";
 	}
}
Event.observe(window,'load', externalLinks, false);

/** 
 * change alpha opacity to a div element (just for IE)
 */
function changeAlpha(img){
	var theElement = document.getElementById(img);
	if (theElement.className == "normal")
		theElement.className = "hover";
	else
		theElement.className = "normal";
}
