// JavaScript Document
////////////////////////////////////	
var AlbumPath="";
var arrANIMALS=new Array();
var arrARCHITECTURE=new Array();
var arrBULLRING= new Array();
var arrCONTEMPORARY=new Array();
var arrCREATIVE=new Array();
var arrLANDSCAPES=new Array();
var arrMONO=new Array();
var arrPEOPLE=new Array();
var arrPORTRAITS=new Array();
var arrREPORTAGE=new Array();
var arrROCKNROLL = new Array();
var arrSEASCAPES=new Array();
var arrWEDDINGS=new Array();
var arrWINTER=new Array();
//
////FILL WITH thumbnail IMAGE PATHS
AlbumPath="ALBUMS/animals/thumbs/";
arrANIMALS[1]=AlbumPath + "thmb_jcm001.jpg";
arrANIMALS[2]=AlbumPath + "thmb_jcm002.jpg";
arrANIMALS[3]=AlbumPath + "thmb_jcm003.jpg";
arrANIMALS[4]=AlbumPath + "thmb_jcm004.jpg";
arrANIMALS[5]=AlbumPath + "thmb_jcm005.jpg";
arrANIMALS[6]=AlbumPath + "thmb_jcm006.jpg";
arrANIMALS[7]="";
arrANIMALS[8]="";
arrANIMALS[9]="";
arrANIMALS[10]="";
//
AlbumPath="ALBUMS/architecture/Thumbnails/"
arrARCHITECTURE[1]=AlbumPath + "thmb_843_4325a.jpg";
arrARCHITECTURE[2]=AlbumPath + "thmb_buxton opera house0004.jpg";
arrARCHITECTURE[3]=AlbumPath + "thmb_p_leek0017.jpg";
arrARCHITECTURE[4]=AlbumPath + "thmb_scan8.jpg";
arrARCHITECTURE[5]=AlbumPath + "thmb_Snow Scenes0021a,mono.jpg";
arrARCHITECTURE[6]=AlbumPath + "thmb_the old fire station3psd.jpg";
arrARCHITECTURE[7]="";
arrARCHITECTURE[8]="";
arrARCHITECTURE[9]="";
arrARCHITECTURE[10]="";

AlbumPath="ALBUMS/bullring/"
arrBULLRING[1]=AlbumPath +"thmb_opt_DPP_0415_480x640.jpg";
arrBULLRING[2]=AlbumPath +"thmb_opt_DPP_0418mono_480x640.jpg";
arrBULLRING[3]=AlbumPath +"thmb_opt_DPP_0426_480x640.jpg";
arrBULLRING[4]=AlbumPath +"thmb_opt_IMG_0795_480x640.jpg";
arrBULLRING[5]=AlbumPath +"thmb_opt_IMG_0795mono_480x640.jpg";
arrBULLRING[6]=AlbumPath +"thmb_opt_IMG_0828_480x640.jpg";
arrBULLRING[7]=AlbumPath +"thmb_opt_IMG_0841_480x640.jpg";
arrBULLRING[8]=AlbumPath +"thmb_opt_IMG_0841mono_480x640.jpg";
arrBULLRING[9]=AlbumPath +"thmb_optDPP_0446_640x480.jpg";
arrBULLRING[10]=AlbumPath +"thmb_optDPP_0448mono_640x480.jpg";
arrBULLRING[11]=AlbumPath +"thmb_optIMG_0829_640x480.jpg";
arrBULLRING[12]=AlbumPath +"thmb_optIMG_0854_640x480.jpg";


AlbumPath="ALBUMS/contemporary/"
arrCONTEMPORARY[1]=AlbumPath +"thmb_022_19 copy.jpg";
arrCONTEMPORARY[2]=AlbumPath + "thmb_842_4258.jpg";
arrCONTEMPORARY[3]=AlbumPath + "thmb_lakes sept050020.jpg";
arrCONTEMPORARY[4]=AlbumPath + "thmb_roaches 22-1-040035.jpg";
arrCONTEMPORARY[5]=AlbumPath + "thmb_roaches at night0003.jpg";
arrCONTEMPORARY[6]=AlbumPath + "thmb_sept 4th0018.jpg";
arrCONTEMPORARY[7]="";
arrCONTEMPORARY[8]="";
arrCONTEMPORARY[9]="";
arrCONTEMPORARY[10]="";

AlbumPath="ALBUMS/creative/"
arrCREATIVE[1]=AlbumPath + "thmb_842_4293.jpg";
arrCREATIVE[2]=AlbumPath + "thmb_angel hi res crop0014.jpg";
arrCREATIVE[3]=AlbumPath + "thmb_colours0003.jpg";
arrCREATIVE[4]=AlbumPath + "thmb_img_0438.jpg";
arrCREATIVE[5]=AlbumPath + "thmb_p_wedding0306a.jpg";
arrCREATIVE[6]=AlbumPath + "thmb_raw0008a.jpg";
arrCREATIVE[7]=AlbumPath + "thmb_yvonne and allan's wedding0306a.jpg";
arrCREATIVE[8]="";
arrCREATIVE[9]="";
arrCREATIVE[10]="";

AlbumPath="ALBUMS/Local landscapes/"
arrLANDSCAPES[1]=AlbumPath + "thmb_0022.jpg";
arrLANDSCAPES[2]=AlbumPath + "thmb_844_4447.jpg";
arrLANDSCAPES[3]=AlbumPath + "thmb_daisies0001.jpg";
arrLANDSCAPES[4]=AlbumPath + "thmb_grass0014.jpg";
arrLANDSCAPES[5]=AlbumPath + "thmb_may 140023.jpg";
arrLANDSCAPES[6]=AlbumPath + "thmb_opt_IMG_7299a_480x640.jpg";
arrLANDSCAPES[7]=AlbumPath + "thmb_opt_IMG_8088_480x640.jpg";
arrLANDSCAPES[8]=AlbumPath + "thmb_optflyer_640x480.jpg";
arrLANDSCAPES[9]=AlbumPath + "thmb_optIMG_0020a_640x480.jpg";
arrLANDSCAPES[10]=AlbumPath + "thmb_optIMG_0460_640x480.jpg";
arrLANDSCAPES[11]=AlbumPath + "thmb_optIMG_0604_640x480.jpg";
arrLANDSCAPES[12]=AlbumPath + "thmb_optIMG_0605_640x480.jpg";
arrLANDSCAPES[13]=AlbumPath + "thmb_optIMG_9974A_640x480.jpg";
arrLANDSCAPES[14]=AlbumPath + "thmb_roaches & tittesworth0029 copy.jpg";

AlbumPath="ALBUMS/mono/"
arrMONO[1]=AlbumPath + "thmb_850_5054b.jpg";
arrMONO[2]=AlbumPath + "thmb_850_5062.jpg";
arrMONO[3]=AlbumPath + "thmb_edale aug050024.jpg";
arrMONO[4]=AlbumPath + "thmb_hen cloud sept15-030005 copy2.jpg";
arrMONO[5]=AlbumPath + "thmb_lakes july 050001.jpg";
arrMONO[6]=AlbumPath + "thmb_roaches 0062 copy.jpg";
arrMONO[7]="";
arrMONO[8]="";
arrMONO[9]="";
arrMONO[10]="";

AlbumPath="ALBUMS/people/"
arrPEOPLE[1]=AlbumPath + "thmb_edale aug050063.jpg";
arrPEOPLE[2]=AlbumPath + "thmb_opt_IMG_0074_480x640.jpg";
arrPEOPLE[3]=AlbumPath + "thmb_opt_IMG_9405_480x640.jpg";
arrPEOPLE[4]=AlbumPath + "thmb_opt_sara1_480x640.jpg";
arrPEOPLE[5]=AlbumPath + "thmb_p_847_4726.jpg";
arrPEOPLE[6]=AlbumPath + "thmb_p_wiltshire0006.jpg";
arrPEOPLE[7]=AlbumPath + "thmb_turkiye 20050007.jpg";
arrPEOPLE[8]=AlbumPath + "thmb_turkiye 20050025.jpg";
arrPEOPLE[9]="";
arrPEOPLE[10]="";

AlbumPath="ALBUMS/portraits/"
arrPORTRAITS[1]=AlbumPath + "thmb_opt_897_9788_480x640.jpg";
arrPORTRAITS[2]=AlbumPath + "thmb_opt_IMG_9602_480x640.jpg";
arrPORTRAITS[3]=AlbumPath + "thmb_opt_IMG_9607_480x640.jpg";
arrPORTRAITS[4]=AlbumPath + "thmb_optIMG_7573a copy_640x480.jpg";
arrPORTRAITS[5]="";
arrPORTRAITS[6]="";
arrPORTRAITS[7]="";
arrPORTRAITS[8]="";
arrPORTRAITS[9]="";
arrPORTRAITS[10]="";

AlbumPath="ALBUMS/reportage/"
arrREPORTAGE[1]=AlbumPath + "thmb_9.jpg";
arrREPORTAGE[2]=AlbumPath + "thmb_fire station demolition0011.jpg";
arrREPORTAGE[3]=AlbumPath + "thmb_nicholson war memorial0089.jpg";
arrREPORTAGE[4]=AlbumPath + "thmb_nicholson war memorial0143.jpg";
arrREPORTAGE[5]=AlbumPath + "thmb_p_fire station demolition0011.jpg";
arrREPORTAGE[6]=AlbumPath + "thmb_sunday league football0111.jpg";
arrREPORTAGE[7]=AlbumPath + "thmb_turkiye 20050001.jpg";
arrREPORTAGE[8]="";
arrREPORTAGE[9]="";
arrREPORTAGE[10]="";

AlbumPath="ALBUMS/rock n roll/"
arrROCKNROLL[1]=AlbumPath + "thmb_opt_IMG_6833_1_480x640.jpg";
arrROCKNROLL[2]=AlbumPath + "thmb_opt_IMG_6844_1_480x640.jpg";
arrROCKNROLL[3]=AlbumPath + "thmb_opt_IMG_6847_1_480x640.jpg";
arrROCKNROLL[4]=AlbumPath + "thmb_opt_IMG_6900_480x640.jpg";
arrROCKNROLL[5]=AlbumPath + "thmb_optIMG_6664_640x480.jpg";
arrROCKNROLL[6]=AlbumPath + "thmb_optIMG_6666_640x480.jpg";
arrROCKNROLL[7]=AlbumPath + "thmb_optIMG_6738_640x480.jpg";
arrROCKNROLL[8]=AlbumPath + "thmb_optIMG_6833_640x480.jpg";
arrROCKNROLL[9]=AlbumPath + "thmb_optIMG_6849_640x480.jpg";
arrROCKNROLL[10]="";

AlbumPath="ALBUMS/seascapes/"
arrSEASCAPES[1]=AlbumPath + "thmb_022.jpg";
arrSEASCAPES[2]=AlbumPath + "thmb_cornwall050031.jpg";
arrSEASCAPES[3]=AlbumPath + "thmb_cornwall050047.jpg";
arrSEASCAPES[4]=AlbumPath + "thmb_turkiye 20050001a.jpg";
arrSEASCAPES[5]=AlbumPath + "thmb_turkiye 20050076.jpg";
arrSEASCAPES[6]=AlbumPath + "thmb_turkiye 20050081.jpg";
arrSEASCAPES[7]="";
arrSEASCAPES[8]="";
arrSEASCAPES[9]="";
arrSEASCAPES[10]="";

AlbumPath="ALBUMS/weddings/"
arrWEDDINGS[1]=AlbumPath + "thmb_opt_IMG_7754_480x640.jpg";
arrWEDDINGS[2]=AlbumPath + "thmb_opt_IMG_7756_480x640.jpg";
arrWEDDINGS[3]=AlbumPath + "thmb_opt_IMG_7801_480x640.jpg";
arrWEDDINGS[4]=AlbumPath + "thmb_opt_IMG_7821_480x640.jpg";
arrWEDDINGS[5]=AlbumPath + "thmb_opt_IMG_7942_480x640.jpg";
arrWEDDINGS[6]=AlbumPath + "thmb_opt_IMG_8073_480x640.jpg";
arrWEDDINGS[7]=AlbumPath + "thmb_opt_IMG_8977_480x640.jpg";
arrWEDDINGS[8]=AlbumPath + "thmb_opt_IMG_8990_480x640.jpg";
arrWEDDINGS[9]=AlbumPath + "thmb_opt_IMG_9095_480x640.jpg";
arrWEDDINGS[10]=AlbumPath + "thmb_opt_IMG_9286_480x640.jpg";
arrWEDDINGS[11]=AlbumPath + "thmb_opt_Yvonne and Allan0012_480x640.jpg";
arrWEDDINGS[12]=AlbumPath + "thmb_optIMG_7968_640x480.jpg";
arrWEDDINGS[13]=AlbumPath + "thmb_optIMG_8011_640x480.jpg";
arrWEDDINGS[14]=AlbumPath + "thmb_optIMG_8887_640x480.jpg";

AlbumPath="ALBUMS/winter/"
arrWINTER[1]=AlbumPath + "thmb_more snow scenes0027.jpg";
arrWINTER[2]=AlbumPath + "thmb_more snow scenes0054.jpg";
arrWINTER[3]=AlbumPath + "thmb_scan9.jpg";
arrWINTER[4]=AlbumPath + "thmb_snow scenes0002.jpg";
arrWINTER[5]=AlbumPath + "thmb_snow scenes0025.jpg";
arrWINTER[6]=AlbumPath + "thmb_snow scenes0062.jpg";
arrWINTER[7]="";
arrWINTER[8]="";
arrWINTER[9]="";
arrWINTER[10]="";
//

/////////////////////////////////////////////////////////////////////	
	
	function here(elemid) {
			
			alert ("DEBUG:" + "\n here: " + elemid);
			
			
			}
////////////////////////////////////////////////////////////////////			
			function SetImageSource(ElemID, placeholder) {
	
	
	//<!-- set the src tag for the orderphoto placeholder element when listImage Clicked-->
	var LstImage = (document.all) ? document.all(ElemID) : document.getElementById(ElemID);
	var photo = (document.all) ? document.all(placeholder) : document.getElementById(placeholder);
	
//	alert ("SetImageSource" + " " + ElemID + " " + placeholder + " selected=" + LstImage.value);
	
	//******** MUST SET THE SIZE TO BE EITHER LANDSCAPE OR PORTRAIT *****
	
	if (LstImage.value) {
	photo.src=LstImage.value;
	
	} 
	else 	{
	photo.src="";
	}
	
	}

//       ///////////////////////////////////////////////////////////////////		
					function SetList (ListName){
		
		var childname="listImage"; //name of target list
		var childopts=0;
		var Lst = (document.all) ? document.all(ListName) : document.getElementById(ListName);
			
		if (!Lst) {
		alert ("No ALBUM list found!");
		return false;
		}
		
		var childlist=(document.all) ? document.all(childname) : document.getElementById(childname);
		var selected="";
		var photo="";
	
	if (!childlist) {
		alert ("No picture list found!");
		return false;
		}
		
		childopts=childlist.options.length;
	if (childopts == 0) {
	//	alert ("no picture list options!");	
		//return false;
		}
		
		
		var arr= new Array(); 
		var arrayname="";
		var CellCount=0;

		
		selected = Lst.options[Lst.selectedIndex].value.toUpperCase();
		
	//	photo=childlist.options[childlist.selectedIndex].value;
		
		//alert("SetList: Fill List items -ALBUM Selected option=" + selected );	
		
		//fill childlist from appropriate array
//		childlist.options.length=0;
		
switch (selected) {
	case "ANIMALS":	//<!-- load up the list with the image paths from the Animmals Directory-->
	arr=arrANIMALS;
	//alert ("animals album chosen LENGTH="+ arr.length);
	break;
	
	case "ARCHITECTURE":
		//	<!-- load up the list with the image paths from the Animmals Directory-->
	arr=arrARCHITECTURE;
	//alert ("architecture album chosen LENGTH="+ arr.length);
	break;
	
	case "BULLRING":
	//alert ("Bullring List Chosen");
	arr=arrBULLRING;
	break;

	case "CONTEMPORARY":
//		<!-- load up the list with the image paths from the Directory-->
	arr=arrCONTEMPORARY;
	break;
	case "CREATIVE":
//		<!-- load up the list with the image paths from the Directory-->
	arr=arrCREATIVE;
	break;
	case "LANDSCAPES":
//		<!-- load up the list with the image paths from the Directory-->
	arr=arrLANDSCAPES;
	break;
	case "MONO":
//		<!-- load up the list with the image paths from the Directory-->
	arr=arrMONO;
	break;
	case "PEOPLE":
//		<!-- load up the list with the image paths from the Directory-->
	arr=arrPEOPLE;
	break;
	case "PORTRAITS":
	arr=arrPORTRAITS;
	break;
	
	case "REPORTAGE":
//		<!-- load up the list with the image paths from the Directory-->
	arr=arrREPORTAGE;
	break;
	
	case "ROCKNROLL":
	arr=arrROCKNROLL;
	break;
	
	case "SEASCAPES":
//		<!-- load up the list with the image paths from the Directory-->
	arr=arrSEASCAPES;
	break;
	
	case "WEDDINGS":
	arr=arrWEDDINGS;
	break;
	
	case "WINTER":
//		<!-- load up the list with the image paths from the Directory-->
	arr=arrWINTER;
	break;
	
	
	default:
		alert ("DEFAULT: list not found!");
	return;
	}
	
	// fill the child list from the array
//	alert ("Fill child list - array.length="  + arr.length);
	
	childlist.options.length=0;
	var i;
	
	for (i=0; i<=arr.length; i++){
	
	if(!arr[i]==""){
		
		var newopt=document.createElement('OPTION');
		newopt.text="picture" + i;
		newopt.value=arr[i];
			
	try{
		childlist.options.add(newopt, null);  // wont work in IE	
		}
	catch (ex) {
		childlist.options.add(newopt);
			}
	}// if clause
	
	}// end of loop

// SELECT THE FIRST PICTURE
	
	if (childlist.options.length){
	childlist.options[0].selected="selected";
	SetImageSource('listImage','orderphoto');
	}
	
}/////////////////////////////