window.thumbnails = {};
															thumbnails[1747598] = clik.newPhoto({"id":1747598,"src":"0491_thumb_1.jpg","galleries_id":"","server_id":15,"link":"#","width":148,"caption":"","height":200});
															thumbnails[1933888] = clik.newPhoto({"id":1933888,"src":"029_thumb.jpg","galleries_id":"","server_id":15,"link":"#","width":130,"caption":"","height":104});
															thumbnails[1933910] = clik.newPhoto({"id":1933910,"src":"030_thumb.jpg","galleries_id":"","server_id":15,"link":"#","width":130,"caption":"","height":93});
															thumbnails[7424423] = clik.newPhoto({"id":7424423,"src":"0002_KSC1713_thumb.jpg","galleries_id":"","server_id":15,"link":"#","width":130,"caption":"","height":98});
															thumbnails[7424514] = clik.newPhoto({"id":7424514,"src":"049_DSC5243_thumb.jpg","galleries_id":"","server_id":15,"link":"#","width":130,"caption":"","height":98});
															thumbnails[7424524] = clik.newPhoto({"id":7424524,"src":"067_DSC6350_thumb.jpg","galleries_id":"","server_id":15,"link":"#","width":130,"caption":"","height":98});
															thumbnails[7424764] = clik.newPhoto({"id":7424764,"src":"0016_thumb.jpg","galleries_id":"","server_id":15,"link":"#","width":130,"caption":"","height":98});
															thumbnails[7424972] = clik.newPhoto({"id":7424972,"src":"0036_DSC7271_thumb.jpg","galleries_id":"","server_id":15,"link":"#","width":130,"caption":"","height":173});
															thumbnails[7424979] = clik.newPhoto({"id":7424979,"src":"0036_LSC5494_thumb.jpg","galleries_id":"","server_id":15,"link":"#","width":130,"caption":"","height":173});
															thumbnails[9091555] = clik.newPhoto({"id":9091555,"src":"002_Sample_Album_4_thumb1_1.jpg","galleries_id":"","server_id":15,"link":"#","width":200,"caption":"","height":157});
															thumbnails[1933804] = clik.newPhoto({"id":1933804,"src":"009_thumb.jpg","galleries_id":129667,"server_id":15,"link":"photo_1933804.html","width":130,"caption":"","height":193});
															thumbnails[1933810] = clik.newPhoto({"id":1933810,"src":"010_thumb.jpg","galleries_id":129667,"server_id":15,"link":"photo_1933810.html","width":130,"caption":"","height":196});
															thumbnails[1933869] = clik.newPhoto({"id":1933869,"src":"023_thumb.jpg","galleries_id":129667,"server_id":15,"link":"photo_1933869.html","width":130,"caption":"","height":182});
															thumbnails[1933914] = clik.newPhoto({"id":1933914,"src":"011_thumb.jpg","galleries_id":129667,"server_id":15,"link":"photo_1933914.html","width":130,"caption":"","height":176});
															thumbnails[1933928] = clik.newPhoto({"id":1933928,"src":"018_thumb.jpg","galleries_id":129667,"server_id":15,"link":"photo_1933928.html","width":130,"caption":"","height":176});
															thumbnails[1934016] = clik.newPhoto({"id":1934016,"src":"015_thumb.jpg","galleries_id":129667,"server_id":15,"link":"photo_1934016.html","width":130,"caption":"","height":176});
															thumbnails[1934026] = clik.newPhoto({"id":1934026,"src":"025_thumb.jpg","galleries_id":129667,"server_id":15,"link":"photo_1934026.html","width":130,"caption":"","height":182});
															thumbnails[1934027] = clik.newPhoto({"id":1934027,"src":"026_thumb.jpg","galleries_id":129667,"server_id":15,"link":"photo_1934027.html","width":130,"caption":"","height":163});
															thumbnails[1934031] = clik.newPhoto({"id":1934031,"src":"021_thumb.jpg","galleries_id":129667,"server_id":15,"link":"photo_1934031.html","width":130,"caption":"","height":196});
															thumbnails[1934037] = clik.newPhoto({"id":1934037,"src":"034_thumb.jpg","galleries_id":129667,"server_id":15,"link":"photo_1934037.html","width":130,"caption":"","height":186});
															thumbnails[1934040] = clik.newPhoto({"id":1934040,"src":"035_thumb.jpg","galleries_id":129667,"server_id":15,"link":"photo_1934040.html","width":130,"caption":"","height":176});
															thumbnails[1934041] = clik.newPhoto({"id":1934041,"src":"036_thumb.jpg","galleries_id":129667,"server_id":15,"link":"photo_1934041.html","width":130,"caption":"","height":182});
															thumbnails[1934179] = clik.newPhoto({"id":1934179,"src":"037_thumb.jpg","galleries_id":129667,"server_id":15,"link":"photo_1934179.html","width":130,"caption":"","height":176});
															thumbnails[1934182] = clik.newPhoto({"id":1934182,"src":"039_thumb.jpg","galleries_id":129667,"server_id":15,"link":"photo_1934182.html","width":130,"caption":"","height":176});
															thumbnails[1934184] = clik.newPhoto({"id":1934184,"src":"040_thumb.jpg","galleries_id":129667,"server_id":15,"link":"photo_1934184.html","width":130,"caption":"","height":176});
															thumbnails[1934186] = clik.newPhoto({"id":1934186,"src":"041_thumb.jpg","galleries_id":129667,"server_id":15,"link":"photo_1934186.html","width":130,"caption":"","height":176});
															thumbnails[7420414] = clik.newPhoto({"id":7420414,"src":"0045_KSC1925_thumb.jpg","galleries_id":129667,"server_id":15,"link":"photo_7420414.html","width":130,"caption":"","height":173});
															thumbnails[7424500] = clik.newPhoto({"id":7424500,"src":"031_DSC5901_thumb.jpg","galleries_id":129667,"server_id":15,"link":"photo_7424500.html","width":130,"caption":"","height":173});
															thumbnails[7424501] = clik.newPhoto({"id":7424501,"src":"037_DSC5171_thumb.jpg","galleries_id":129667,"server_id":15,"link":"photo_7424501.html","width":130,"caption":"","height":173});
															thumbnails[7424510] = clik.newPhoto({"id":7424510,"src":"041_DSC5178_thumb.jpg","galleries_id":129667,"server_id":15,"link":"photo_7424510.html","width":130,"caption":"","height":173});
															thumbnails[7424517] = clik.newPhoto({"id":7424517,"src":"051_DSC6115_thumb.jpg","galleries_id":129667,"server_id":15,"link":"photo_7424517.html","width":130,"caption":"","height":173});
															thumbnails[7424527] = clik.newPhoto({"id":7424527,"src":"072_DSC5403_thumb.jpg","galleries_id":129667,"server_id":15,"link":"photo_7424527.html","width":130,"caption":"","height":173});
															thumbnails[7424530] = clik.newPhoto({"id":7424530,"src":"0072_KSC3150_thumb.jpg","galleries_id":129667,"server_id":15,"link":"photo_7424530.html","width":130,"caption":"","height":173});
															thumbnails[7424531] = clik.newPhoto({"id":7424531,"src":"0075_KSC2403_thumb.jpg","galleries_id":129667,"server_id":15,"link":"photo_7424531.html","width":130,"caption":"","height":173});
															thumbnails[7424533] = clik.newPhoto({"id":7424533,"src":"076_KSC0612_thumb.jpg","galleries_id":129667,"server_id":15,"link":"photo_7424533.html","width":130,"caption":"","height":173});
															thumbnails[7424967] = clik.newPhoto({"id":7424967,"src":"0033__KSC1610_thumb.jpg","galleries_id":129667,"server_id":15,"link":"photo_7424967.html","width":130,"caption":"","height":173});
															thumbnails[7424989] = clik.newPhoto({"id":7424989,"src":"0037_KSC6762_thumb.jpg","galleries_id":129667,"server_id":15,"link":"photo_7424989.html","width":130,"caption":"","height":173});
															thumbnails[7424992] = clik.newPhoto({"id":7424992,"src":"069_KSC0527_thumb.jpg","galleries_id":129667,"server_id":15,"link":"photo_7424992.html","width":130,"caption":"","height":173});
															thumbnails[7459439] = clik.newPhoto({"id":7459439,"src":"0042_LSC3510_thumb.jpg","galleries_id":129667,"server_id":15,"link":"photo_7459439.html","width":130,"caption":"","height":173});
															thumbnails[7459447] = clik.newPhoto({"id":7459447,"src":"0049_KSC3691_thumb.jpg","galleries_id":129667,"server_id":15,"link":"photo_7459447.html","width":130,"caption":"","height":173});
															thumbnails[7459525] = clik.newPhoto({"id":7459525,"src":"0064_KSC3875_thumb.jpg","galleries_id":129667,"server_id":15,"link":"photo_7459525.html","width":130,"caption":"","height":173});
															thumbnails[7459526] = clik.newPhoto({"id":7459526,"src":"0065_KSC3891_thumb.jpg","galleries_id":129667,"server_id":15,"link":"photo_7459526.html","width":130,"caption":"","height":173});
															thumbnails[7459531] = clik.newPhoto({"id":7459531,"src":"0067_KSC3936_thumb.jpg","galleries_id":129667,"server_id":15,"link":"photo_7459531.html","width":130,"caption":"","height":173});
															thumbnails[7459533] = clik.newPhoto({"id":7459533,"src":"0068_KSC3980_thumb.jpg","galleries_id":129667,"server_id":15,"link":"photo_7459533.html","width":130,"caption":"","height":173});
															thumbnails[7459536] = clik.newPhoto({"id":7459536,"src":"0069_KSC3982_thumb.jpg","galleries_id":129667,"server_id":15,"link":"photo_7459536.html","width":130,"caption":"","height":173});
															thumbnails[7459539] = clik.newPhoto({"id":7459539,"src":"0074_KSC4068_thumb.jpg","galleries_id":129667,"server_id":15,"link":"photo_7459539.html","width":130,"caption":"","height":173});
															thumbnails[7459542] = clik.newPhoto({"id":7459542,"src":"0072_KSC4052_thumb.jpg","galleries_id":129667,"server_id":15,"link":"photo_7459542.html","width":130,"caption":"","height":173});
															thumbnails[7559966] = clik.newPhoto({"id":7559966,"src":"Album_-_Warrior_-_Portsmouth_001_thumb1_3.jpg","galleries_id":409758,"server_id":15,"link":"photo_7559966.html","width":200,"caption":"","height":157});
															thumbnails[7559973] = clik.newPhoto({"id":7559973,"src":"Album_-_Warrior_-_Portsmouth_002_thumb1_2.jpg","galleries_id":409758,"server_id":15,"link":"photo_7559973.html","width":200,"caption":"","height":157});
															thumbnails[7559975] = clik.newPhoto({"id":7559975,"src":"Album_-_Warrior_-_Portsmouth_003_thumb1_1.jpg","galleries_id":409758,"server_id":15,"link":"photo_7559975.html","width":200,"caption":"","height":157});
															thumbnails[7559977] = clik.newPhoto({"id":7559977,"src":"Album_-_Warrior_-_Portsmouth_004_thumb1_1.jpg","galleries_id":409758,"server_id":15,"link":"photo_7559977.html","width":200,"caption":"","height":157});
															thumbnails[7559978] = clik.newPhoto({"id":7559978,"src":"Album_-_Warrior_-_Portsmouth_005_thumb1_2.jpg","galleries_id":409758,"server_id":15,"link":"photo_7559978.html","width":200,"caption":"","height":157});
															thumbnails[7559981] = clik.newPhoto({"id":7559981,"src":"Album_-_Warrior_-_Portsmouth_006_thumb1_1.jpg","galleries_id":409758,"server_id":15,"link":"photo_7559981.html","width":200,"caption":"","height":157});
															thumbnails[7559983] = clik.newPhoto({"id":7559983,"src":"Album_-_Warrior_-_Portsmouth_007_thumb1_2.jpg","galleries_id":409758,"server_id":15,"link":"photo_7559983.html","width":200,"caption":"","height":157});
															thumbnails[7559984] = clik.newPhoto({"id":7559984,"src":"Album_-_Warrior_-_Portsmouth_008_thumb1_2.jpg","galleries_id":409758,"server_id":15,"link":"photo_7559984.html","width":200,"caption":"","height":157});
															thumbnails[7559986] = clik.newPhoto({"id":7559986,"src":"Album_-_Warrior_-_Portsmouth_009_thumb1_1.jpg","galleries_id":409758,"server_id":15,"link":"photo_7559986.html","width":200,"caption":"","height":157});
															thumbnails[7559988] = clik.newPhoto({"id":7559988,"src":"Album_-_Warrior_-_Portsmouth_010_thumb1_1.jpg","galleries_id":409758,"server_id":15,"link":"photo_7559988.html","width":200,"caption":"","height":157});
															thumbnails[7559989] = clik.newPhoto({"id":7559989,"src":"Album_-_Warrior_-_Portsmouth_011_thumb1_1.jpg","galleries_id":409758,"server_id":15,"link":"photo_7559989.html","width":200,"caption":"","height":157});
															thumbnails[7559990] = clik.newPhoto({"id":7559990,"src":"Album_-_Warrior_-_Portsmouth_012_thumb1_1.jpg","galleries_id":409758,"server_id":15,"link":"photo_7559990.html","width":200,"caption":"","height":157});
															thumbnails[7559991] = clik.newPhoto({"id":7559991,"src":"Album_-_Warrior_-_Portsmouth_013_thumb1_1.jpg","galleries_id":409758,"server_id":15,"link":"photo_7559991.html","width":200,"caption":"","height":157});
															thumbnails[7560001] = clik.newPhoto({"id":7560001,"src":"Album_-_Warrior_-_Portsmouth_014_thumb1_1.jpg","galleries_id":409758,"server_id":15,"link":"photo_7560001.html","width":200,"caption":"","height":157});
															thumbnails[7560002] = clik.newPhoto({"id":7560002,"src":"Album_-_Warrior_-_Portsmouth_015_thumb1_1.jpg","galleries_id":409758,"server_id":15,"link":"photo_7560002.html","width":200,"caption":"","height":157});
															thumbnails[7560003] = clik.newPhoto({"id":7560003,"src":"Album_-_Warrior_-_Portsmouth_016_thumb1_1.jpg","galleries_id":409758,"server_id":15,"link":"photo_7560003.html","width":200,"caption":"","height":157});
															thumbnails[7560005] = clik.newPhoto({"id":7560005,"src":"Album_-_Warrior_-_Portsmouth_017_thumb1_1.jpg","galleries_id":409758,"server_id":15,"link":"photo_7560005.html","width":200,"caption":"","height":157});
															thumbnails[7560006] = clik.newPhoto({"id":7560006,"src":"Album_-_Warrior_-_Portsmouth_018_thumb1_1.jpg","galleries_id":409758,"server_id":15,"link":"photo_7560006.html","width":200,"caption":"","height":157});
															thumbnails[7560007] = clik.newPhoto({"id":7560007,"src":"Album_-_Warrior_-_Portsmouth_019_thumb1_1.jpg","galleries_id":409758,"server_id":15,"link":"photo_7560007.html","width":200,"caption":"","height":157});
															thumbnails[7560008] = clik.newPhoto({"id":7560008,"src":"Album_-_Warrior_-_Portsmouth_020_thumb1_1.jpg","galleries_id":409758,"server_id":15,"link":"photo_7560008.html","width":200,"caption":"","height":157});
															thumbnails[9091553] = clik.newPhoto({"id":9091553,"src":"001_Sample_Album_4_thumb1_1.jpg","galleries_id":479713,"server_id":15,"link":"photo_9091553.html","width":200,"caption":"","height":157});
															thumbnails[9091570] = clik.newPhoto({"id":9091570,"src":"002_Sample_Album_5_thumb1_2.jpg","galleries_id":479713,"server_id":15,"link":"photo_9091570.html","width":200,"caption":"","height":157});
															thumbnails[9091599] = clik.newPhoto({"id":9091599,"src":"003_Sample_Album_5_thumb1_1.jpg","galleries_id":479713,"server_id":15,"link":"photo_9091599.html","width":200,"caption":"","height":157});
															thumbnails[9091601] = clik.newPhoto({"id":9091601,"src":"004_Sample_Album_5_thumb1_1.jpg","galleries_id":479713,"server_id":15,"link":"photo_9091601.html","width":200,"caption":"","height":157});
															thumbnails[9091607] = clik.newPhoto({"id":9091607,"src":"005_Sample_Album_5_thumb1_1.jpg","galleries_id":479713,"server_id":15,"link":"photo_9091607.html","width":200,"caption":"","height":157});
															thumbnails[9091608] = clik.newPhoto({"id":9091608,"src":"006_Sample_Album_4_thumb1_1.jpg","galleries_id":479713,"server_id":15,"link":"photo_9091608.html","width":200,"caption":"","height":157});
															thumbnails[9091610] = clik.newPhoto({"id":9091610,"src":"007_Sample_Album_4_thumb1_2.jpg","galleries_id":479713,"server_id":15,"link":"photo_9091610.html","width":200,"caption":"","height":157});
															thumbnails[9091616] = clik.newPhoto({"id":9091616,"src":"008_Sample_Album_4_thumb1_1.jpg","galleries_id":479713,"server_id":15,"link":"photo_9091616.html","width":200,"caption":"","height":157});
															thumbnails[9091617] = clik.newPhoto({"id":9091617,"src":"009_Sample_Album_4_thumb1_1.jpg","galleries_id":479713,"server_id":15,"link":"photo_9091617.html","width":200,"caption":"","height":157});
															thumbnails[9091619] = clik.newPhoto({"id":9091619,"src":"010_Sample_Album_4_thumb1_1.jpg","galleries_id":479713,"server_id":15,"link":"photo_9091619.html","width":200,"caption":"","height":157});
															thumbnails[9091634] = clik.newPhoto({"id":9091634,"src":"011_Sample_Album_4_thumb1_1.jpg","galleries_id":479713,"server_id":15,"link":"photo_9091634.html","width":200,"caption":"","height":157});
															thumbnails[9091637] = clik.newPhoto({"id":9091637,"src":"012_Sample_Album_4_thumb1_1.jpg","galleries_id":479713,"server_id":15,"link":"photo_9091637.html","width":200,"caption":"","height":157});
															thumbnails[9091640] = clik.newPhoto({"id":9091640,"src":"013_Sample_Album_3_thumb1_1.jpg","galleries_id":479713,"server_id":15,"link":"photo_9091640.html","width":200,"caption":"","height":157});
															thumbnails[9091641] = clik.newPhoto({"id":9091641,"src":"014_Sample_Album_3_thumb1_1.jpg","galleries_id":479713,"server_id":15,"link":"photo_9091641.html","width":200,"caption":"","height":157});
															thumbnails[9091642] = clik.newPhoto({"id":9091642,"src":"015_Sample_Album_3_thumb1_1.jpg","galleries_id":479713,"server_id":15,"link":"photo_9091642.html","width":200,"caption":"","height":157});
															thumbnails[9091645] = clik.newPhoto({"id":9091645,"src":"016_Sample_Album_3_thumb1_1.jpg","galleries_id":479713,"server_id":15,"link":"photo_9091645.html","width":200,"caption":"","height":157});
															thumbnails[9091646] = clik.newPhoto({"id":9091646,"src":"017_Sample_Album_3_thumb1_1.jpg","galleries_id":479713,"server_id":15,"link":"photo_9091646.html","width":200,"caption":"","height":157});
															thumbnails[9091648] = clik.newPhoto({"id":9091648,"src":"018_Sample_Album_3_thumb1_1.jpg","galleries_id":479713,"server_id":15,"link":"photo_9091648.html","width":200,"caption":"","height":157});
															thumbnails[9091650] = clik.newPhoto({"id":9091650,"src":"019_Sample_Album_3_thumb1_1.jpg","galleries_id":479713,"server_id":15,"link":"photo_9091650.html","width":200,"caption":"","height":157});
															thumbnails[9091653] = clik.newPhoto({"id":9091653,"src":"020_Sample_Album_3_thumb1_1.jpg","galleries_id":479713,"server_id":15,"link":"photo_9091653.html","width":200,"caption":"","height":157});
															thumbnails[9091654] = clik.newPhoto({"id":9091654,"src":"021_Sample_Album_3_thumb1_1.jpg","galleries_id":479713,"server_id":15,"link":"photo_9091654.html","width":200,"caption":"","height":157});
															thumbnails[9091656] = clik.newPhoto({"id":9091656,"src":"022_Sample_Album_3_thumb1_1.jpg","galleries_id":479713,"server_id":15,"link":"photo_9091656.html","width":200,"caption":"","height":157});
															thumbnails[9091660] = clik.newPhoto({"id":9091660,"src":"023_Sample_Album_3_thumb1_1.jpg","galleries_id":479713,"server_id":15,"link":"photo_9091660.html","width":200,"caption":"","height":157});
															thumbnails[9091664] = clik.newPhoto({"id":9091664,"src":"024_Sample_Album_3_thumb1_1.jpg","galleries_id":479713,"server_id":15,"link":"photo_9091664.html","width":200,"caption":"","height":157});
															thumbnails[9091665] = clik.newPhoto({"id":9091665,"src":"025_Sample_Album_3_thumb1_1.jpg","galleries_id":479713,"server_id":15,"link":"photo_9091665.html","width":200,"caption":"","height":157});
															thumbnails[9091666] = clik.newPhoto({"id":9091666,"src":"026_Sample_Album_3_thumb1_1.jpg","galleries_id":479713,"server_id":15,"link":"photo_9091666.html","width":200,"caption":"","height":157});
															thumbnails[9091668] = clik.newPhoto({"id":9091668,"src":"027_Sample_Album_3_thumb1_1.jpg","galleries_id":479713,"server_id":15,"link":"photo_9091668.html","width":200,"caption":"","height":157});
															thumbnails[9091670] = clik.newPhoto({"id":9091670,"src":"028_Sample_Album_3_thumb1_1.jpg","galleries_id":479713,"server_id":15,"link":"photo_9091670.html","width":200,"caption":"","height":157});
															thumbnails[9091672] = clik.newPhoto({"id":9091672,"src":"029_Sample_Album_3_thumb1_1.jpg","galleries_id":479713,"server_id":15,"link":"photo_9091672.html","width":200,"caption":"","height":157});
															thumbnails[9091674] = clik.newPhoto({"id":9091674,"src":"030_Sample_Album_3_thumb1_1.jpg","galleries_id":479713,"server_id":15,"link":"photo_9091674.html","width":200,"caption":"","height":157});

/***************************************************************************
* Create the array of Gallery objects                                      *
***************************************************************************/
var galleries = new Object();
				  						galleries[129667] = clik.newGallery({"parentGallery":"","usePopups":true,"title":"The Day","link":"gallery_129667.html","maxRecords":0.0,"photoIDs":[1933804.0,1933810.0,1933869.0,1933914.0,1933928.0,1934016.0,1934026.0,1934027.0,1934031.0,1934037.0,1934040.0,1934041.0,1934179.0,1934182.0,1934184.0,1934186.0,7420414.0,7424500.0,7424501.0,7424510.0,7424517.0,7424527.0,7424530.0,7424531.0,7424533.0,7424967.0,7424989.0,7424992.0,7459439.0,7459447.0,7459525.0,7459526.0,7459531.0,7459533.0,7459536.0,7459539.0,7459542.0],"skipIndex":0,"section_code":"gallery","featured_images":"7459542,7459539,7459536,7459533,7459531,7459525,7459447,7424992,7424967,7424533,7424531,7424530,7424517,7424500,7420414,1934027,1934026,1933928,1933914,1933804","id":129667,"singleSection":false});				  						galleries[409758] = clik.newGallery({"parentGallery":"","usePopups":true,"title":"Sample Album","link":"gallery_409758.html","maxRecords":0.0,"photoIDs":[7559966.0,7559973.0,7559975.0,7559977.0,7559978.0,7559981.0,7559983.0,7559984.0,7559986.0,7559988.0,7559989.0,7559990.0,7559991.0,7560001.0,7560002.0,7560003.0,7560005.0,7560006.0,7560007.0,7560008.0],"skipIndex":0,"section_code":"gallery","featured_images":7559966.0,"id":409758,"singleSection":false});				  						galleries[479713] = clik.newGallery({"parentGallery":"","usePopups":true,"title":"Sample Album 2","link":"gallery_479713.html","maxRecords":0.0,"photoIDs":[9091553.0,9091570.0,9091599.0,9091601.0,9091607.0,9091608.0,9091610.0,9091616.0,9091617.0,9091619.0,9091634.0,9091637.0,9091640.0,9091641.0,9091642.0,9091645.0,9091646.0,9091648.0,9091650.0,9091653.0,9091654.0,9091656.0,9091660.0,9091664.0,9091665.0,9091666.0,9091668.0,9091670.0,9091672.0,9091674.0],"skipIndex":0,"section_code":"gallery","featured_images":9091553.0,"id":479713,"singleSection":false});/***************************************************************************
* Create the array of image sets                                           *
***************************************************************************/
var imageSets = {};
imageSets[1] = '7459542,7459539,7459536,7459533,7459531,7459525,7424533,7424531,7424530,7424517,7424500,7420414,1934026,1933928,1747598';
imageSets[2] = '9091553,7559966,7459542,7459539,7459536,7459533,7459531,7459525,7459447,7424992,7424979,7424972,7424967,7424533,7424531,7424530,7424517,7424500,7420414,1934027,1934026,1933928,1933914,1933804';
imageSets[3] = '7560008,7560007,7560006,7560005,7560003,7560002,7560001,7559991,7559990,7559989,7559988,7559986,7559984,7559983,7559981,7559978,7559977,7559975,7559973,7459542,7459539,7459536,7459533,7459531,7459526,7459525,7459447,7459439,7424992,7424989,7424979,7424972,7424967,7424764,7424533,7424531,7424530,7424527,7424524,7424517,7424514,7424510,7424501,7424500,7424423,7420414,1934186,1934184,1934182,1934179,1934041,1934037,1934031,1934027,1934026,1934016,1933928,1933914,1933810,1933804';
 /***************************************************************************
* Get a server path given an ID                                            *
***************************************************************************/
function getServerPath(server_id) {
	var val = -1;
		switch (server_id) {
		case 51:
		val = 'http://www12.clikpic.com/kenbreed/images';
		break;
	}
		switch (server_id) {
		case 0:
		val = 'http://www.clikpic.com/kenbreed/images';
		break;
	}
		switch (server_id) {
		case 1:
		val = 'http://www1.clikpic.com/kenbreed/images';
		break;
	}
		switch (server_id) {
		case 2:
		val = 'http://admin.clikpic.com/kenbreed/images';
		break;
	}
		switch (server_id) {
		case 24:
		val = 'http://tpc15/clikpic/kenbreed/images';
		break;
	}
		switch (server_id) {
		case 4:
		val = 'http://clikchurch.clikpic.com/kenbreed/images';
		break;
	}
		switch (server_id) {
		case 5:
		val = 'http://www2.clikpic.com/kenbreed/images';
		break;
	}
		switch (server_id) {
		case 22:
		val = 'http://tpc5/clikpic/kenbreed/images';
		break;
	}
		switch (server_id) {
		case 23:
		val = 'http://tpc10/clikpic/kenbreed/images';
		break;
	}
		switch (server_id) {
		case 25:
		val = 'http://tpc16/clikpic/kenbreed/images';
		break;
	}
		switch (server_id) {
		case 26:
		val = 'http://tpc20/clikpic/kenbreed/images';
		break;
	}
		switch (server_id) {
		case 40:
		val = 'http://www11.clikpic.com/kenbreed/images';
		break;
	}
		switch (server_id) {
		case 42:
		val = 'db2.clikpic.com/kenbreed/images';
		break;
	}
		switch (server_id) {
		case 15:
		val = 'http://www3.clikpic.com/kenbreed/images';
		break;
	}
		switch (server_id) {
		case 18:
		val = 'http://www4.clikpic.com/kenbreed/images';
		break;
	}
		switch (server_id) {
		case 19:
		val = 'http://www5.clikpic.com/kenbreed/images';
		break;
	}
		switch (server_id) {
		case 31:
		val = 'http://www7.clikpic.com/kenbreed/images';
		break;
	}
		switch (server_id) {
		case 32:
		val = 'http://www8.clikpic.com/kenbreed/images';
		break;
	}
		switch (server_id) {
		case 34:
		val = 'http://www9.clikpic.com/kenbreed/images';
		break;
	}
		switch (server_id) {
		case 35:
		val = 'http://admin3.clikpic.com/kenbreed/images';
		break;
	}
		switch (server_id) {
		case 37:
		val = 'http://admin4.clikpic.com/kenbreed/images';
		break;
	}
		switch (server_id) {
		case 38:
		val = 'http://admin5.clikpic.com/kenbreed/images';
		break;
	}
		switch (server_id) {
		case 39:
		val = 'http://www10.clikpic.com/kenbreed/images';
		break;
	}
		switch (server_id) {
		case 53:
		val = 'http://images.clikpic.com/kenbreed/images';
		break;
	}
		switch (server_id) {
		case 52:
		val = 'http://tpc22/clikpic/kenbreed/images';
		break;
	}
		switch (server_id) {
		case 21:
		val = 'http://www6.clikpic.com/kenbreed/images';
		break;
	}
		switch (server_id) {
		case 50:
		val = '[cliktext value=article.servers_id type=servers_id]/kenbreed/images';
		break;
	}
		return val;
}

/***************************************************************************
* img = reference to image object in which to show image                   *
***************************************************************************/
function showHomeImage(img) {
	imageID = randomListVal('');
	if (!basic) {
		img.src = photos[imageID].src;
		img.width = photos[imageID].width;
		img.height = photos[imageID].height;
		img.parentNode.title = img.alt = photos[imageID].caption;
	} else {
		newImage = new Image(photos[imageID].width,photos[imageID].height);
		newImage.src = photos[imageID].src;
		document.images[img.name] = newImage;
		
	}
}

function getHomeImageLink(imageID) {
  	var href='', photo = (backgrounds || photos || {})[imageID];
	if(photo){
		if (photo && photo.galleries_id != '') {
  			href = photo.fnGalleryLink();
  		}
  		  		else {
  				href += 'gallery.html';
  	  		}
	}
    return href;
}

/***************************************************************************
* Show a random image on home page from featured images                    *
***************************************************************************/
function showHomeImageInline(el, image_sets_id, href) {
	
	var css = {}, imageID,
	    imageSetsId = 1;
	if(image_sets_id){
		imageSetsId = image_sets_id;
	}
	imageID = randomListVal(imageSets[imageSetsId]);
	if (href == null && 'gallery' != '') {
					href = getHomeImageLink(imageID);
	}
	
	updateImage({nextPhoto: backgrounds[imageID], img:el.find('img')[0],
                $photo:el, $title:$('#homeimageTitleContainer'), $detail:$('#homeimageDetailsContainer'),                speed:0, href:href, css:css, onAfter: function(){                  this.closest('.contentsection').doManualAlign({				    inner: 'img',				    crop: 'a'				  });                }              });
}

/***************************************************************************
* Set 'img' to be a new image given its photo() object                     *
***************************************************************************/
function updateImage (options) {
	var defaults = {nextPhoto:'',field:'',img:'',$photo:'',$title:'',$detail:'',$detailContainer:'',
                    updateDocumentTitle:false,speed:0,href:false,css:false,updateHash:false,onAfter:null,onBefore:null},
		op = $.extend({},defaults,options),
		html = '', temp = '',
		photoId = op.nextPhoto.id,
		photoCaption = ''+op.nextPhoto.caption,
		photoSrc = op.nextPhoto.src;
	
	if (op.updateHash && clik.getIDInUrl(location.href,'photo') != op.nextPhoto.id) {
		clik.changeHash('photos_id=' + op.nextPhoto.id, true);
	}
		
	    if (op.$title.length > 0) {
  		op.$title.fadeGalleryDetails(photoCaption, op.speed);
    }
        if (op.updateDocumentTitle) {
						  document.title = 'K-Lyn Photography - 07946 307885: ' + photoCaption;
			    }
        if (op.$detail.length > 0) {
      	temp = op.nextPhoto.fnGetImageDetails();
	    op.$detail.fadeGalleryDetails(temp, op.speed, function(){
			if (typeof(backgrounds) != 'undefined' && op.nextPhoto == backgrounds[op.nextPhoto.id]) {
				toggleAddToCartConfirm(backgrounds, op.$detail);
			} else if (typeof(photos) != 'undefined' && op.nextPhoto == photos[op.nextPhoto.id]) {
				toggleAddToCartConfirm(photos, op.$detail);
			}
			$('body').trigger('clikUpdate.popup');
	    });
    }
        $(op.$detailContainer).find('.replaceable[class*=replaceable_photo-]').each(function(){
    	var field = clik.getPrefixedClass(this.className, 'replaceable_photo-');
    	if (field in op.nextPhoto) {
    		$(this).fadeGalleryDetails(op.nextPhoto[field], op.speed);
    	}
    }).end().find('.replaceable.photoPayment').fadeGalleryDetails(op.nextPhoto.fnGetPaymentInfo(), op.speed, function(){
		if (typeof(backgrounds) != 'undefined' && op.nextPhoto == backgrounds[op.nextPhoto.id]) {
			toggleAddToCartConfirm(backgrounds, op.$detailContainer);
		} else if (typeof(photos) != 'undefined' && op.nextPhoto == photos[op.nextPhoto.id]) {
			toggleAddToCartConfirm(photos, op.$detailContainer);
		}
		$('body').trigger('clikUpdate.popup');
	});
		if (op.$photo.length > 0) {
		html = $('<img/>',{
			'class': 'mainphoto photo',
			src: photoSrc,
			id: 'mainPic',
			name: 'mainPic',
			width: op.nextPhoto.width,
			height: op.nextPhoto.height,
			alt: photoCaption,
			css: op.css || {}
		});
		if (op.href) {
			if (op.href.match(/<a/)) {
				html = $(op.href).append(html);
			} else {
				html = $('<a/>', {
					href: op.href,
					title: photoCaption
				}).append(html);
			}
		} else {
			html = $('<a/>', {
				title: photoCaption
			}).append(html);
		}
		if (op.speed == 0) {			op.$photo.html(html);			if (op.onBefore) {			  	op.onBefore.apply(op.$photo);			}			if (op.onAfter) {			  	op.onAfter.apply(op.$photo);			}		} else {			op.$photo.stop(true,true).fadeReplaceWith(html,op.speed,'',function(){  				if (op.onAfter) {				  	op.onAfter.apply(this);				}				clik.doColumnResize(false, $(this).add(op.$detail).add(op.$title));			}, op.onBefore);
		}	}
    if (op.field) {
		op.field.value = photoId;
	} else {
		op.$photo.data('image_id', photoId);
    }
        if (!op.speed) {
      	clik.doColumnResize(false, op.$photo.add(op.$detail).add(op.$title));
    }
        
    return html;
	}

/***************************************************************************
* Toggle add to cart confirmation element and set up the click event for   *
* the 'Add to cart' button.                                                *
***************************************************************************/
function toggleAddToCartConfirm(array, root){
	if (typeof(array) !== 'object' || array === null) {
	  	array = photos;
	}
	if (!$(root).length) {		root = $('body');	}	if($('#paymentConfirm', root).length > 0){
		$('#paymentConfirm', root).hide();
		$('#paymentAddButton', root)
		.unbind()
		.click(function(){
						form = $('#paymentForm', root)[0];
			option_id = 0;
			if(form.item_option.value){
				option_id = form.item_option.value;
			}
			if(addItemToBasket(form.item_number.value,array,form.site.value,parseInt(form.quantity.value, 10),option_id)){
				if($.browser.msie){$('#paymentConfirm', root).text('Item added to cart').show();}
				else{
					$('#paymentConfirm', root).text('Item added to cart').fadeIn();
					dspOrderDetails(form.site.value);
				}
			}
			else{
				$('#paymentConfirm', root).text('Item not added - check cookies are enabled in your browser.').fadeIn();
			}
		});
	}
}

/***************************************************************************
* Get payment info for image - add as 'method' to photo object             *
***************************************************************************/
clik.photo.fnGetImageDetails = function(){
	var temp = '';
	if (this.description != '') {
		temp +=  '<div id="imageDescription">' + this.description + '</div>';
	}
		if (this.photo_ref != '') {
		temp += '<div class="imageinfo" id="imageRef"><strong>Ref: </strong>' + this.photo_ref + '</div>';
	}
		if (this.takendate != '') {
		
		temp += '<div class="imageinfo" id="imageDate"><strong>Date: </strong>' + this.takendate + '</div>';
	}
	
	if (this.location != '') {
		
		temp += '<div class="imageinfo" id="imageLocation"><strong>Location: </strong>' +  this.location + '</div>';
	}
	
	if (this.photographer != '') {
		
		temp += '<div class="imageinfo" id="imagePhotographer"><strong>Photographer: </strong>' + this.photographer + '</div>';
	}
				
				if (temp != '') {
		temp += '<div class="spacer"></div>';
	}
	return temp;
};

/***************************************************************************
* Get payment info for image - add as 'method' to photo object             *
***************************************************************************/
clik.photo.fnGetPaymentInfo = function(){
	var temp = '';
	if (this.item_price !== '') {
				temp += '<p>Order this print:</p>';
				temp += '<div class="imageinfo" id="imagePrice"><strong>' + this.purchase_instruction + '</strong> ' + (this.item_price).toFixed(2) + '</div>';
		var item_name  = this.purchase_instruction;
		var amount = (this.item_price).toFixed(2);
		var item_option  = 0;
	}
		else {
		
	}
	if (this.item_price !== '') {
			temp += '<div class="clearing">&nbsp;</div>';
	}
	return temp;};

/***************************************************************************
* Pick a photo at random from the featured images of a gallery.            *
* Gallery_id = id of gallery to choose,                                    *
* img = reference to html image in                                         *
* which to show image                                                      *
***************************************************************************/
function showGalleryImage(gallery_id, img, updateLink) {
	
	if(img){
		if (location.hash.match('galleries_id=' + gallery_id) && (imageID = location.hash.match('.*photos_id=(.+)$'))) {
		  	imageID = imageID[1];
		} else {
		  	imageID = randomListVal(galleries[gallery_id].featured_images);
		}
		
		if (imageID != 0) {
			img.src = thumbnails[imageID].src;
			img.width = thumbnails[imageID].width;
			img.height = thumbnails[imageID].height;
			img.alt = galleries[gallery_id].title;
			if (updateLink) {
				$(img).parent().attr({					title: galleries[gallery_id].title				}).filter(function(){return this.href;}).attr({					href: thumbnails[imageID].fnGalleryLink(gallery_id)				});
			}
		}
	}
}

/***************************************************************************
* If we have dynamic HTML, replace the galleries link with a list that     *
* doesn't include thecurrent gallery                                       *
***************************************************************************/
function showGalleries(gallery_id) {
		
	
	if (!basic) {
		temp = '';
		for (i = 0; i < galleries.length; i++) {
						
			
			if (galleries[i].id != gallery_id) {
								
				if (temp != '') {
					temp += ' | ';
				}
								temp += '<a href="' + galleries[i].section_code + '_' + galleries[i].id + '.html">' + galleries[i].title + '</a>';
							}
		}
		document.all.galleryLinks.innerHTML = 'Other galleries: ' + temp;
	}
}

			

