
tees = new Array(
	"And-Green-KT-tunic", "And-KT-red-T-hammock", "And-Tara", "dani-palms", 
	"green-TY-close-up", "katz-n-baseman", "logo-close-up", "Mys-b_w-KT-black-T",
	"Mys-happy-green-Guru-nat-T", "pillow-fight", "Shea-Mystic", "Tara-KT-black-T-bubble", 
	"Trav-And-Bunny-Hammock", "xxxASS", "COAL-WHT-THANK-B", "CRKTCO1L", "NAT-GRN-KNOW-B", "NAT-GRN-THANK-G", "NAT-RED-THANK-B", "RASP-BLK-HEART-B",	"VERDE-BLK-KNOW-B", "RASP-WHT-THANK-M", "RASP-WHT-THANK-B", "RASP-WHT-KNOW-B", "RASP-WHT-KNOW-G", "VERDE-BLK-THANK-B", "RASP-WHT-GURU-B"
);

cards = new Array(
	"09-heart-eye-boy-site", "09-heart-eye-girl-site", "09-heart-shirt-site", "09-heart-thought-site", 
	"09-i-heart-horns-site", "09-love-is-here", "09-love-we-always-site", "09-skyscape-site"
);




large = new Image;
current_image = 0;

function chg_image(direction, dir, imgarray)
{
	if(document.images) {

		current_image += direction;
		
		if(current_image>(imgarray.length - 1)) {
			current_image=0
		}
		else if(current_image<0) {
			current_image=(imgarray.length - 1);
		}
		imagename = imgarray[current_image];

		var content = "large";;
		slash = dir.indexOf('/');
		if(slash!=-1) {
			temp = dir.split('/');
			content += temp[1];
		}
		document[content].src="images/" + dir + "/" + imagename + ".jpg";
	}
}

function search_image(imagename, imgarray)
{
	var i;
	found = 0;
	for(i=0; i<imgarray.length && !found; i++) {
		if(imagename==imgarray[i])
			found = i;
	}

	return found;
}

function loadimage(imagename, dir, imgarray) {
	var content = "large";;
	slash = dir.indexOf('/');
	if(slash!=-1) {
		temp = dir.split('/');
		content += temp[1];
	}
	document[content].src="images/" + dir + "/" + imagename + ".jpg";
	current_image = search_image(imagename, imgarray);
	changeText(document.getElementById('imgcaption'))
} 