

function getRandomImageFromSet(setName){
	getRandomImageFromSetWithTags(setName,'');
}


function getRandomImageFromSetWithTags(setName, tags){
	getRandomImageFromSetWithTagsFromPath(setName, tags, '');
}


function getRandomImageFromSetWithTagsFromPath(setName, tags, path){
	var feetCount = 61;
	var aboutMePicsCount = 25;
	var imgNumber = -1;
	var imgCount = 0;
	var imgName = '';
	
	if(setName=='feet'){
		imgCount = feetCount;
	}else if(setName=='aboutMePics'){
		imgCount = aboutMePicsCount;
	}
	
	imgNumber = Math.ceil(Math.random() * imgCount);
	if (imgNumber < 1000) { imgName = '0' + imgNumber;}
	if (imgNumber < 100) { imgName = '00' + imgNumber;}
	if (imgNumber < 10) { imgName = '000' + imgNumber;}
	document.write("<img src="+path+"gfx/"+setName+"/"+setName+imgName+".jpg "+tags+">");

}

function shadowImageLink(imageName, imageWidth, imageHeight, gfxPath, linkString)		
	{							
		document.writeln("<TABLE BORDER='0'  CELLSPACING='0' CELLPADDING='0' BGCOLOR='#FFFFFF'><TR>")
		document.writeln("<TR><TD width='50%'>&nbsp;<\/TD><TD colspan=3>&nbsp;<\/TD><TD width='50%'>&nbsp;<\/TD><\/TR>")
		document.writeln("<TD ROWSPAN ='3'>&nbsp;<\/TD>")
		document.writeln("<TD ROWSPAN='2'  colspan='2' WIDTH='"+imageWidth+"' HEIGHT='"+imageHeight+"'><a href='"+ linkString +"'>")		//document.writeln("<IMG SRC='"+imageName+"' WIDTH='"+imageWidth+"' HEIGHT='"+imageHeight+"' border=0><\/a><\/TD>")		document.writeln("<IMG SRC='"+imageName+"'  border=0><\/a><\/TD>")		document.writeln("<TD WIDTH='6' HEIGHT='9' VALIGN='bottom' align='left'><IMG SRC='"+ gfxPath +"/shadowtopright.gif' WIDTH='6' HEIGHT='9'><\/TD>")
		document.writeln("<TD ROWSPAN ='3'>&nbsp;<\/TD>")
		document.writeln("<\/TR>")		document.writeln("<TR>")		document.writeln("<TD WIDTH='6' HEIGHT='"+(imageHeight-9)+"'><IMG SRC='"+ gfxPath +"/shadowright.gif' WIDTH='6' HEIGHT='"+(imageHeight-9)+"'><\/TD>")		document.writeln("<\/TR>")		document.writeln("<TR>")		document.writeln("<TD WIDTH='7' HEIGHT='6' valign='top' align='right'><IMG SRC='"+ gfxPath +"/shadowbottomleft.gif' WIDTH='7' HEIGHT='6'><\/TD>")		document.writeln("<TD WIDTH='"+(imageWidth-7)+"' HEIGHT='6'  valign='top'><IMG SRC='"+ gfxPath +"/shadowbottom.gif' WIDTH='"+(imageWidth-7)+"' HEIGHT='6'><\/TD>")		document.writeln("<TD WIDTH='6' HEIGHT='6' valign='top' align='left'><IMG SRC='"+ gfxPath +"/shadowbottomright.gif' WIDTH='6' HEIGHT='6'><\/TD>")		document.writeln("<\/TR>")
		document.writeln("<\/TABLE>")
	}		

function shadowImageSimple(imageName, imageWidth, imageHeight, gfxPath)		
	{							
		document.writeln("<TABLE BORDER='0'  CELLSPACING='0' CELLPADDING='0' BGCOLOR='#FFFFFF'><TR>")
		document.writeln("<TR><TD width='50%'>&nbsp;<\/TD><TD colspan=3>&nbsp;<\/TD><TD width='50%'>&nbsp;<\/TD><\/TR>")
		document.writeln("<TD ROWSPAN ='3'>&nbsp;<\/TD>")
		document.writeln("<TD ROWSPAN='2'  colspan='2' WIDTH='"+imageWidth+"' HEIGHT='"+imageHeight+"'>")		document.writeln("<IMG SRC='"+imageName+"'  border=0><\/TD>")		document.writeln("<TD WIDTH='6' HEIGHT='9' VALIGN='bottom' align='left'><IMG SRC='"+ gfxPath +"/shadowtopright.gif' WIDTH='6' HEIGHT='9'><\/TD>")
		document.writeln("<TD ROWSPAN ='3'>&nbsp;<\/TD>")
		document.writeln("<\/TR>")		document.writeln("<TR>")		document.writeln("<TD WIDTH='6' HEIGHT='"+(imageHeight-9)+"'><IMG SRC='"+ gfxPath +"/shadowright.gif' WIDTH='6' HEIGHT='"+(imageHeight-9)+"'><\/TD>")		document.writeln("<\/TR>")		document.writeln("<TR>")		document.writeln("<TD WIDTH='7' HEIGHT='6' valign='top' align='right'><IMG SRC='"+ gfxPath +"/shadowbottomleft.gif' WIDTH='7' HEIGHT='6'><\/TD>")		document.writeln("<TD WIDTH='"+(imageWidth-7)+"' HEIGHT='6'  valign='top'><IMG SRC='"+ gfxPath +"/shadowbottom.gif' WIDTH='"+(imageWidth-7)+"' HEIGHT='6'><\/TD>")		document.writeln("<TD WIDTH='6' HEIGHT='6' valign='top' align='left'><IMG SRC='"+ gfxPath +"/shadowbottomright.gif' WIDTH='6' HEIGHT='6'><\/TD>")		document.writeln("<\/TR>")
		
		document.writeln("<\/TABLE>")
	}							
 					

function shadowImage(imageName, linkString, gfxPath)	
	{
		shadowImageTitle(imageName, linkString, gfxPath, '');	
	}
function shadowImageTitle(imageName, linkString, gfxPath, imgTitle)		
	{							
		document.writeln("<TABLE BORDER='0' CELLSPACING='0' CELLPADDING='0' BGCOLOR='#FFFFFF' >")
		document.writeln("<tr>")
		document.writeln("<TD ROWSPAN ='3'><img src='"+gfxPath+"/spacer.gif'><\/TD>")
		document.write("<TD ROWSPAN='2' colspan='2'>")
		if (linkString !='') {
			document.write('<a href="'+linkString+'">')
		}		document.write("<IMG SRC='"+imageName+"' border=0 title='"+imgTitle+"'>");
		if (linkString !='') {
			document.write("<\/a>")
		}
		document.writeln("<\/TD>")		document.writeln("<TD WIDTH='6' HEIGHT='9' VALIGN='top' align='left' background='"+ gfxPath +"/shadowright.gif'><IMG SRC='"+ gfxPath +"/shadowtopright.gif' WIDTH='6' HEIGHT='9'><\/TD>")
		document.writeln("<\/TR>")		document.writeln("<TR>")		document.writeln("<TD WIDTH='6' background='"+ gfxPath +"/shadowright.gif'><img src='"+gfxPath+"/spacer.gif'><\/TD>")
		document.writeln("<\/TR>")		document.writeln("<TR>")
		//document.writeln("<TD height=6><img src='"+gfxPath+"/spacer.gif'><\/TD>")
		document.writeln("<TD HEIGHT='6' width='7' valign='top' align='left' background='"+ gfxPath +"/shadowbottom.gif'><IMG SRC='"+ gfxPath +"/shadowbottomleft.gif' WIDTH='7' HEIGHT='6'><\/TD>")		document.writeln("<TD HEIGHT='6' valign='top' background='"+ gfxPath +"/shadowbottom.gif'><img src='"+gfxPath+"/spacer.gif' height=6><\/TD>")		document.writeln("<TD WIDTH='6' HEIGHT='6' valign='top' align='left'><IMG SRC='"+ gfxPath +"/shadowbottomright.gif' WIDTH='6' HEIGHT='6'><\/TD>")		document.writeln("<\/TR>")
		document.writeln("<\/TABLE>")
	}	



