function thumb_chg(filename) {div=document.getElementById('thumb');div.src="photos/"+filename+"";}function photo_control(piclist,direction) {div=document.getElementById('fullpic');picarr=piclist.split(","); //create array from list of pics sent from control buttons//get current img srccurrentpic=div.getAttribute('src');src=currentpic.split("/");pic=((src.length)-1);//find out which picture we are currently seeingfor(i=0;i<picarr.length;i++) {	if(picarr[i]==src[pic]) {	viewed_pic=i;		}}//add or subtract 1 from the current position to go either back or forthif(direction=='-1') {newpic=viewed_pic-1;}else {newpic=viewed_pic+1;}//if picture is either at the beginning or end of list then don't go any furtherif(newpic<0 || newpic==(i-1)) {newpic=viewed_pic;return;}div.src="photos/full/"+picarr[newpic]+"";//chg thumbnail with pic changethumb_chg(picarr[newpic]);//chg thumbnail numberthumb_nums('',newpic+1);i=0;//fix for f(x). for some reason, if this function is called, i is not reset for the navaction f(x), so reset it here}function photo_blow(display) {//document.getElementById('thumb').style.outline= "0px solid orange";filename=document.getElementById('thumb').src;src=filename.split("/");pic=((src.length)-1);var bigpic=document.getElementById('bigpic');document.getElementById('bigpic').innerHTML="<img id='fullpic' src='photos/full/"+src[pic]+"'>";bigpic.style.display=display;document.getElementById('pic_control').style.display=display;}/*document.getElementById(layer).innerHTML="";photolength=photosarr.length;var pix = new Array();pix = photosarr;if(photolength>1) {	for(i=0; i< photolength; i++) { //paginate		if(i<=5) {		nextpic=photosarr[i];		var ii=i+1;    		links= '<a href="#" onMouseOver=" javascript: rollover(\''+ii+'\',\'imgs/'+ii+'_roll.gif\')" ; onMouseOut=" javascript: rollover(\''+ii+'\',\'imgs/'+ii+'_norm.gif\')"; onClick="javascript: photochange(\''+nextpic+'\',\''+layer+'\',\''+ii+'\')" onfocus=\"this.blur()\"><img id="'+ii+'" src="imgs/'+ii+'_norm.gif"></a>';		newpic = document.createElement("DIV");		newpic.innerHTML=links;				newpic.className='imgpag';		newpic.style.left= i*12+'px';		}//end if	document.getElementById(layer).appendChild(newpic);	}//end for	}//end photolength>1photochange(photosarr[0],layer,'1');    }//end function*/