﻿function showFullText() {
	document.getElementById('fullText').style.visibility = 'visible';
	document.getElementById('fullText').style.height = 'auto';
	document.getElementById('fullText').style.overflow = 'visible';
}

var myImages = new Array();

function preloading()	{
	for (x=0; x<preloading.arguments.length; x++) {
		myImages[x] = new Image();
		myImages[x].src = preloading.arguments[x];
	}
}

preloading (
	"images/menus/aboutDown.jpg",
	"images/menus/concertsDown.jpg",
	"images/menus/educationDown.jpg",
	"images/menus/galleryDown.jpg",
	"images/menus/homeDown.jpg",
	"images/menus/insiderDown.jpg",
	"images/menus/pressDown.jpg",
	"images/menus/supportDown.jpg",
	"images/menus/webLogDown.jpg"
);

function openPhotoWindow(gallery_ID) {
	fileLocation = 'galleryPage.php?gallery_ID=' + gallery_ID + '&current=1';
	album = window.open(fileLocation, 'album', 'directories=false, width=500, height=650, top=50, left=50, menubar=false, status=no, resizable=yes, scrollbars=false');
}

function windowOpen(name, Display) {
	fileLocation = 'staff/' + name + '.html';
	popUp = window.open(fileLocation, 'popUp', 'directories=false, height=400, width=700, top=50, left=50, menubar=false, resizable=yes, scrollbars=yes, status=true, toolbar=false');

}

function windowOpenBio(name, Display) {
	fileLocation = 'staff/' + name + 'Bio.html';
	popUp = window.open(fileLocation, 'popUp', 'directories=false, height=400, width=700, top=50, left=50, menubar=false, resizable=yes, scrollbars=yes, status=true, toolbar=false');
}

function windowOpenYafBio(name) {
	fileLocation = 'yafBios/' + name + '.html';	
	popUp = window.open(fileLocation, 'popUp', 'directories=false, height=400, width=600, top=50, left=50, menubar=false, resizable=yes, scrollbars=yes, status=true, toolbar=false');
}

function buildAddress(user, text) {
	email = user + '@' + 'cmnw' + '.' + 'org';
	emailLink = 'm' + 'a' + 'i' + 'l' + 't' + 'o' + ':' + user + '@' + 'cmnw' + '.' + 'org';
	return "<a href=" + emailLink + ">" + email + "</a>";
}

function printPage(filename) {
	printableWindow = 'printable/' + filename;
	theWindow = window.open(printableWindow, 'theWindow', 'directories=false, height=700, width=600, top=50, left=50, menubar=false, resizalbe=yes, scrollbars=yes, status=true, toolbar=false');
}

function staffPreload() {
	for (x=0; x<staffPreload.arguments.length; x++) {
		myImages[x] = new Image();
		myImages[x].src = staffPreload.arguments[x];	
	}
}

function staffRollover(theImgID) {
	document.getElementById(theImgID).src = '../images/staff/headshots/' + theImgID + '_over.jpg';
}

function staffRollout(theImgID) {
	document.getElementById(theImgID).src = '../images/staff/headshots/' + theImgID + '.jpg';
}

