function imgSwap(pic)
{
	var path = pic.src;
	var overState = "_on";
	var imgStr, hover, type;
	
	if(path.indexOf(".gif") != -1) {
		type = ".gif";
		imgStr = path.substring(0, path.indexOf(type))
		hover = imgStr + overState + type;
	} else if(path.indexOf(".jpg") != -1) {
		type = ".jpg";
		imgStr = path.substring(0, path.indexOf(type))
		hover = imgStr + overState + type;
	} else {
		alert("Unsupported Image Format.");
		type = hover = null;
		pic.onmouseover = null;
		return;
	}
	
	pic.src = hover;
	
	pic.onmouseout = function() {
		path = this.src;
		imgStr = path.substring(0, path.indexOf(overState + type))
		hover = imgStr + type;
		this.src = hover;
		this.onmouseout = null;
	}

}