function writeEmail()
{
	user = "JonesRufiWedding";
	domain = "gmail.com";
	emailAddy = "mailto:" + user + "@" + domain;
	alink = document.getElementById("emailme");
	alink.setAttribute("href", emailAddy);
	alink.setAttribute("title", "Contact Me");
}

function writeEmail2()
{
	user = "JonesRufiWedding";
	domain = "gmail.com";
	emailAddy = "mailto:" + user + "@" + domain;
	alink = document.getElementById("emailme2");
	alink.setAttribute("href", emailAddy);
	alink.setAttribute("title", "Contact Me");
}
function enlarge(picture, spotID)
{
	var spot = document.getElementById(spotID);
	spot.src = picture;
}
function showPerson(person)
{
	var pDiv = document.getElementById("personDiv");
  	pDiv.removeChild(document.getElementById("personInfoDiv"));

	switch(person)
	{
		case 'Crystal':
			showCrystal(pDiv);
			break;
		case 'Jeffrey':
			showJeffrey(pDiv);
			break;
		case 'Callum':
			showCallum(pDiv);
			break;
		case 'David':
			showDavid(pDiv);
			break;
		case 'Emily':
			showEmily(pDiv);
			break;
		case 'Hannah':
			showHannah(pDiv);
			break;
		case 'Robert':
			showRobert(pDiv);
			break;
		case 'Richard':
			showRichard(pDiv);
			break;
		case 'Charles':
			showCharles(pDiv);
			break;
		case 'Rosemarie':
			showRosemarie(pDiv);
			break;
		case 'John':
			showJohn(pDiv);
			break;
		case 'Carol':
			showCarol(pDiv);
			break;
		default:
			break;
	}
}
function createPersonPicture(thumbnail, largeImage)
{
	var link = document.createElement('a');
	link.setAttribute('href', largeImage);
	link.setAttribute('target', 'blank');
	var image = document.createElement('img');
	image.setAttribute('src', thumbnail);
	image.setAttribute('style', '{border-style:none}');
	link.appendChild(image);

	return link;
}
function showCrystal(pDiv)
{
	var infoDiv = document.createElement('div');
	infoDiv.setAttribute('id', "personInfoDiv");
	
	var link = createPersonPicture('/pictures/newAlbum/horses2009Thumb/pinky2009_3.jpg', '/pictures/newAlbum/horses2009/pinky2009_3.jpg')
	infoDiv.appendChild(link);

	link = createPersonPicture('/pictures/newAlbum/horses2009Thumb/smarty2009_28.jpg', '/pictures/newAlbum/horses2009/smarty2009_28.jpg')
	infoDiv.appendChild(link);

	pDiv.appendChild(infoDiv);
}
function showJeffrey(pDiv)
{	var infoDiv = document.createElement('div');
	infoDiv.setAttribute('id', "personInfoDiv");
	
	var link = createPersonPicture('/pictures/newAlbum/jeffrey2P.jpg', '/pictures/newAlbum/jeffrey2.jpg')
	infoDiv.appendChild(link);

	pDiv.appendChild(infoDiv);
}
function showCallum(pDiv)
{

}
function showDavid(pDiv)
{

}
function showEmily(pDiv)
{

}
function showHannah(pDiv)
{

}
function showRobert(pDiv)
{

}
function showRichard(pDiv)
{

}
function showCharles(pDiv)
{

}
function showRosemarie(pDiv)
{

}
function showJohn(pDiv)
{

}
function showCarol(pDiv)
{

}

