window.thumbnails = {};
															thumbnails[311255] = clik.newPhoto({"id":311255,"src":"00192JPG_thumb.jpg","galleries_id":"","server_id":1,"link":"#","width":130,"caption":"1st Team Sponsor","height":84});
															thumbnails[321116] = clik.newPhoto({"id":321116,"src":"IMG_0012JPG_thumb.jpg","galleries_id":"","server_id":1,"link":"#","width":130,"caption":"Carlton Park Hockey FSC","height":93});
															thumbnails[591793] = clik.newPhoto({"id":591793,"src":"DSCF1839JPG_thumb.jpg","galleries_id":"","server_id":1,"link":"#","width":130,"caption":"2nd Team 06\/07 Season","height":98});
															thumbnails[646174] = clik.newPhoto({"id":646174,"src":"00934001_thumb.jpg","galleries_id":"","server_id":1,"link":"#","width":130,"caption":"1st Team 06\/07","height":85});
															thumbnails[2009180] = clik.newPhoto({"id":2009180,"src":"img056-1img056-1_thumb.jpg","galleries_id":"","server_id":1,"link":"#","width":130,"caption":"","height":85});
															thumbnails[2070070] = clik.newPhoto({"id":2070070,"src":"inviteoscarfinalweb_thumb.jpg","galleries_id":"","server_id":1,"link":"#","width":130,"caption":"","height":127});
															thumbnails[591772] = clik.newPhoto({"id":591772,"src":"DSCF1765JPG_thumb.jpg","galleries_id":26670,"server_id":1,"link":"photo_591772.html","width":130,"caption":"Carlton Park II v Grasshoppers II 21\/10\/06","height":98});
															thumbnails[591777] = clik.newPhoto({"id":591777,"src":"DSCF1773JPG_thumb.jpg","galleries_id":26670,"server_id":1,"link":"photo_591777.html","width":130,"caption":"Carlton Park II v Grasshoppers II 21\/10\/06","height":98});
															thumbnails[591778] = clik.newPhoto({"id":591778,"src":"DSCF1778JPG_thumb.jpg","galleries_id":26670,"server_id":1,"link":"photo_591778.html","width":130,"caption":"Carlton Park II v Grasshoppers II 21\/10\/06","height":98});
															thumbnails[591783] = clik.newPhoto({"id":591783,"src":"DSCF1802JPG_thumb.jpg","galleries_id":26670,"server_id":1,"link":"photo_591783.html","width":130,"caption":"Carlton Park II v Grasshoppers II 21\/10\/06","height":173});
															thumbnails[591784] = clik.newPhoto({"id":591784,"src":"DSCF1805JPG_thumb.jpg","galleries_id":26670,"server_id":1,"link":"photo_591784.html","width":130,"caption":"Carlton Park II v Grasshoppers II 21\/10\/06","height":173});
															thumbnails[591785] = clik.newPhoto({"id":591785,"src":"DSCF1817JPG_thumb.jpg","galleries_id":26670,"server_id":1,"link":"photo_591785.html","width":130,"caption":"Carlton Park II v Grasshoppers II 21\/10\/06","height":98});
															thumbnails[591788] = clik.newPhoto({"id":591788,"src":"DSCF1823JPG_thumb.jpg","galleries_id":26670,"server_id":1,"link":"photo_591788.html","width":130,"caption":"Carlton Park II v Grasshoppers II 21\/10\/06","height":173});
															thumbnails[591792] = clik.newPhoto({"id":591792,"src":"DSCF1834JPG_thumb.jpg","galleries_id":26670,"server_id":1,"link":"photo_591792.html","width":130,"caption":"Carlton Park II v Grasshoppers II 21\/10\/06","height":98});
															thumbnails[591796] = clik.newPhoto({"id":591796,"src":"DSCF1841JPG_thumb.jpg","galleries_id":26670,"server_id":1,"link":"photo_591796.html","width":130,"caption":"Carlton Park II v Grasshoppers II 21\/10\/06","height":98});
															thumbnails[591797] = clik.newPhoto({"id":591797,"src":"DSCF1843JPG_thumb.jpg","galleries_id":26670,"server_id":1,"link":"photo_591797.html","width":130,"caption":"Carlton Park II v Grasshoppers II 21\/10\/06","height":98});
															thumbnails[591800] = clik.newPhoto({"id":591800,"src":"DSCF1846JPG_thumb.jpg","galleries_id":26670,"server_id":1,"link":"photo_591800.html","width":130,"caption":"Carlton Park II v Grasshoppers II 21\/10\/06","height":98});
															thumbnails[646176] = clik.newPhoto({"id":646176,"src":"00945012_thumb.jpg","galleries_id":26665,"server_id":1,"link":"photo_646176.html","width":130,"caption":"Carlton Park I v Lowestoft II 09\/12\/06","height":84});
															thumbnails[646179] = clik.newPhoto({"id":646179,"src":"00946013_thumb.jpg","galleries_id":26665,"server_id":1,"link":"photo_646179.html","width":130,"caption":"Carlton Park I v Lowestoft II 09\/12\/06","height":85});
															thumbnails[646182] = clik.newPhoto({"id":646182,"src":"00947014_thumb.jpg","galleries_id":26665,"server_id":1,"link":"photo_646182.html","width":130,"caption":"Carlton Park I v Lowestoft II 09\/12\/06","height":87});
															thumbnails[646189] = clik.newPhoto({"id":646189,"src":"00990057_thumb.jpg","galleries_id":26665,"server_id":1,"link":"photo_646189.html","width":130,"caption":"Carlton Park I v Lowestoft II 09\/12\/06","height":87});
															thumbnails[646191] = clik.newPhoto({"id":646191,"src":"00964031_thumb.jpg","galleries_id":26665,"server_id":1,"link":"photo_646191.html","width":130,"caption":"Carlton Park I v Lowestoft II 09\/12\/06","height":87});
															thumbnails[646193] = clik.newPhoto({"id":646193,"src":"00968035_thumb.jpg","galleries_id":26665,"server_id":1,"link":"photo_646193.html","width":130,"caption":"Carlton Park I v Lowestoft II 09\/12\/06","height":87});
															thumbnails[646195] = clik.newPhoto({"id":646195,"src":"00980047_thumb.jpg","galleries_id":26665,"server_id":1,"link":"photo_646195.html","width":130,"caption":"Carlton Park I v Lowestoft II 09\/12\/06","height":95});
															thumbnails[646196] = clik.newPhoto({"id":646196,"src":"00953020_thumb.jpg","galleries_id":26665,"server_id":1,"link":"photo_646196.html","width":130,"caption":"Carlton Park I v Lowestoft II 09\/12\/06","height":87});
															thumbnails[646203] = clik.newPhoto({"id":646203,"src":"00985052_thumb.jpg","galleries_id":26665,"server_id":1,"link":"photo_646203.html","width":130,"caption":"Carlton Park I v Lowestoft II 09\/12\/06","height":89});
															thumbnails[646205] = clik.newPhoto({"id":646205,"src":"00986053_thumb.jpg","galleries_id":26665,"server_id":1,"link":"photo_646205.html","width":130,"caption":"Carlton Park I v Lowestoft II 09\/12\/06","height":190});
															thumbnails[646207] = clik.newPhoto({"id":646207,"src":"00992059_thumb.jpg","galleries_id":26665,"server_id":1,"link":"photo_646207.html","width":130,"caption":"Carlton Park I v Lowestoft II 09\/12\/06","height":87});
															thumbnails[646211] = clik.newPhoto({"id":646211,"src":"00999066_thumb.jpg","galleries_id":26665,"server_id":1,"link":"photo_646211.html","width":130,"caption":"Carlton Park I v Lowestoft II 09\/12\/06","height":87});
															thumbnails[646213] = clik.newPhoto({"id":646213,"src":"01006073_thumb.jpg","galleries_id":26665,"server_id":1,"link":"photo_646213.html","width":130,"caption":"Carlton Park I v Lowestoft II 09\/12\/06","height":83});
															thumbnails[646215] = clik.newPhoto({"id":646215,"src":"01011078_thumb.jpg","galleries_id":26665,"server_id":1,"link":"photo_646215.html","width":130,"caption":"Carlton Park I v Lowestoft II 09\/12\/06","height":87});
															thumbnails[646217] = clik.newPhoto({"id":646217,"src":"01015082_thumb.jpg","galleries_id":26665,"server_id":1,"link":"photo_646217.html","width":130,"caption":"Carlton Park I v Lowestoft II 09\/12\/06","height":88});
															thumbnails[646221] = clik.newPhoto({"id":646221,"src":"01018085_thumb.jpg","galleries_id":26665,"server_id":1,"link":"photo_646221.html","width":130,"caption":"Carlton Park I v Lowestoft II 09\/12\/06","height":92});
															thumbnails[646229] = clik.newPhoto({"id":646229,"src":"00983050_thumb.jpg","galleries_id":26665,"server_id":1,"link":"photo_646229.html","width":130,"caption":"Carlton Park I v Lowestoft II 09\/12\/06","height":93});
															thumbnails[646233] = clik.newPhoto({"id":646233,"src":"00972039_thumb.jpg","galleries_id":26665,"server_id":1,"link":"photo_646233.html","width":130,"caption":"Carlton Park I v Lowestoft II 09\/12\/06","height":81});
															thumbnails[646235] = clik.newPhoto({"id":646235,"src":"00974041_thumb.jpg","galleries_id":26665,"server_id":1,"link":"photo_646235.html","width":130,"caption":"Carlton Park I v Lowestoft II 09\/12\/06","height":90});
															thumbnails[646236] = clik.newPhoto({"id":646236,"src":"01008075_thumb.jpg","galleries_id":26665,"server_id":1,"link":"photo_646236.html","width":130,"caption":"Carlton Park I v Lowestoft II 09\/12\/06","height":87});
															thumbnails[646237] = clik.newPhoto({"id":646237,"src":"01019086_thumb.jpg","galleries_id":26665,"server_id":1,"link":"photo_646237.html","width":130,"caption":"Carlton Park I v Lowestoft II 09\/12\/06","height":93});
															thumbnails[646238] = clik.newPhoto({"id":646238,"src":"01020087_thumb.jpg","galleries_id":26665,"server_id":1,"link":"photo_646238.html","width":130,"caption":"Carlton Park I v Lowestoft II 09\/12\/06","height":90});
															thumbnails[646239] = clik.newPhoto({"id":646239,"src":"01022089_thumb.jpg","galleries_id":26665,"server_id":1,"link":"photo_646239.html","width":130,"caption":"Carlton Park I v Lowestoft II 09\/12\/06","height":83});
															thumbnails[1710021] = clik.newPhoto({"id":1710021,"src":"anna xmas party_thumb.jpg","galleries_id":50499,"server_id":1,"link":"photo_1710021.html","width":130,"caption":"","height":98});
															thumbnails[1710023] = clik.newPhoto({"id":1710023,"src":"PC230935_thumb.jpg","galleries_id":50499,"server_id":1,"link":"photo_1710023.html","width":130,"caption":"","height":98});
															thumbnails[1710024] = clik.newPhoto({"id":1710024,"src":"PC230937_thumb.jpg","galleries_id":50499,"server_id":1,"link":"photo_1710024.html","width":130,"caption":"","height":98});
															thumbnails[1710026] = clik.newPhoto({"id":1710026,"src":"PC230940_thumb.jpg","galleries_id":50499,"server_id":1,"link":"photo_1710026.html","width":130,"caption":"","height":98});
															thumbnails[1710029] = clik.newPhoto({"id":1710029,"src":"PC230943_thumb.jpg","galleries_id":50499,"server_id":1,"link":"photo_1710029.html","width":130,"caption":"","height":98});
															thumbnails[1710030] = clik.newPhoto({"id":1710030,"src":"PC230946_thumb.jpg","galleries_id":50499,"server_id":1,"link":"photo_1710030.html","width":130,"caption":"","height":98});
															thumbnails[1710033] = clik.newPhoto({"id":1710033,"src":"PC230950_thumb.jpg","galleries_id":50499,"server_id":1,"link":"photo_1710033.html","width":130,"caption":"","height":98});
															thumbnails[1710035] = clik.newPhoto({"id":1710035,"src":"PC230954_thumb.jpg","galleries_id":50499,"server_id":1,"link":"photo_1710035.html","width":130,"caption":"","height":98});
															thumbnails[1710039] = clik.newPhoto({"id":1710039,"src":"PC230956_thumb.jpg","galleries_id":50499,"server_id":1,"link":"photo_1710039.html","width":130,"caption":"","height":98});
															thumbnails[1710040] = clik.newPhoto({"id":1710040,"src":"PC230957_thumb.jpg","galleries_id":50499,"server_id":1,"link":"photo_1710040.html","width":130,"caption":"","height":98});
															thumbnails[1710041] = clik.newPhoto({"id":1710041,"src":"PC230975_thumb.jpg","galleries_id":50499,"server_id":1,"link":"photo_1710041.html","width":130,"caption":"","height":98});
															thumbnails[1710042] = clik.newPhoto({"id":1710042,"src":"PC230995_thumb.jpg","galleries_id":50499,"server_id":1,"link":"photo_1710042.html","width":130,"caption":"","height":98});
															thumbnails[2043220] = clik.newPhoto({"id":2043220,"src":"DSC02596DSC02596_thumb.jpg","galleries_id":136620,"server_id":1,"link":"photo_2043220.html","width":130,"caption":"Haverhill II v Carlton Park II 29\/03\/08.","height":98});
															thumbnails[2043221] = clik.newPhoto({"id":2043221,"src":"cp1cp1_thumb.jpg","galleries_id":136620,"server_id":1,"link":"photo_2043221.html","width":130,"caption":"Haverhill II v Carlton Park II 29\/03\/08.","height":98});
															thumbnails[2043222] = clik.newPhoto({"id":2043222,"src":"cp2cp2_thumb.jpg","galleries_id":136620,"server_id":1,"link":"photo_2043222.html","width":130,"caption":"Haverhill II v Carlton Park II 29\/03\/08.","height":69});
															thumbnails[2043223] = clik.newPhoto({"id":2043223,"src":"cp3cp3_thumb.jpg","galleries_id":136620,"server_id":1,"link":"photo_2043223.html","width":130,"caption":"Haverhill II v Carlton Park II 29\/03\/08.","height":77});
															thumbnails[2043226] = clik.newPhoto({"id":2043226,"src":"cp4cp4_thumb.jpg","galleries_id":136620,"server_id":1,"link":"photo_2043226.html","width":130,"caption":"Haverhill II v Carlton Park II 29\/03\/08.","height":70});
															thumbnails[2043227] = clik.newPhoto({"id":2043227,"src":"cp5cp5_thumb.jpg","galleries_id":136620,"server_id":1,"link":"photo_2043227.html","width":130,"caption":"Haverhill II v Carlton Park II 29\/03\/08.","height":59});
															thumbnails[2043228] = clik.newPhoto({"id":2043228,"src":"cp6cp6_thumb.jpg","galleries_id":136620,"server_id":1,"link":"photo_2043228.html","width":130,"caption":"Haverhill II v Carlton Park II 29\/03\/08.","height":87});
															thumbnails[2043229] = clik.newPhoto({"id":2043229,"src":"cp7cp7_thumb.jpg","galleries_id":136620,"server_id":1,"link":"photo_2043229.html","width":130,"caption":"Haverhill II v Carlton Park II 29\/03\/08.","height":72});
															thumbnails[7297548] = clik.newPhoto({"id":7297548,"src":"PB060186-1_thumb.jpg","galleries_id":49247,"server_id":1,"link":"photo_7297548.html","width":130,"caption":"","height":98});
															thumbnails[7560636] = clik.newPhoto({"id":7560636,"src":"DSC_3833-1_thumb.jpg","galleries_id":409790,"server_id":1,"link":"photo_7560636.html","width":130,"caption":"","height":85});
															thumbnails[7560639] = clik.newPhoto({"id":7560639,"src":"DSC_3841-1_thumb.jpg","galleries_id":409790,"server_id":1,"link":"photo_7560639.html","width":130,"caption":"","height":197});
															thumbnails[7560640] = clik.newPhoto({"id":7560640,"src":"DSC_3850-1_thumb.jpg","galleries_id":409790,"server_id":1,"link":"photo_7560640.html","width":130,"caption":"","height":86});
															thumbnails[7560642] = clik.newPhoto({"id":7560642,"src":"DSC_3862-1_thumb.jpg","galleries_id":409790,"server_id":1,"link":"photo_7560642.html","width":130,"caption":"","height":85});
															thumbnails[7560643] = clik.newPhoto({"id":7560643,"src":"DSC_3863-1_thumb.jpg","galleries_id":409790,"server_id":1,"link":"photo_7560643.html","width":130,"caption":"","height":85});
															thumbnails[7560644] = clik.newPhoto({"id":7560644,"src":"DSC_3872-1_thumb.jpg","galleries_id":409790,"server_id":1,"link":"photo_7560644.html","width":130,"caption":"","height":85});
															thumbnails[7560645] = clik.newPhoto({"id":7560645,"src":"DSC_3878-1_thumb.jpg","galleries_id":409790,"server_id":1,"link":"photo_7560645.html","width":130,"caption":"","height":85});
															thumbnails[7560647] = clik.newPhoto({"id":7560647,"src":"DSC_3889-1_thumb.jpg","galleries_id":409790,"server_id":1,"link":"photo_7560647.html","width":130,"caption":"","height":85});
															thumbnails[7560648] = clik.newPhoto({"id":7560648,"src":"DSC_3907-1_thumb.jpg","galleries_id":409790,"server_id":1,"link":"photo_7560648.html","width":130,"caption":"","height":85});
															thumbnails[7560649] = clik.newPhoto({"id":7560649,"src":"DSC_3913-1_thumb.jpg","galleries_id":409790,"server_id":1,"link":"photo_7560649.html","width":130,"caption":"","height":85});
															thumbnails[7560651] = clik.newPhoto({"id":7560651,"src":"DSC_3935-1_thumb.jpg","galleries_id":409790,"server_id":1,"link":"photo_7560651.html","width":130,"caption":"","height":198});
															thumbnails[7560652] = clik.newPhoto({"id":7560652,"src":"DSC_3966-1_thumb.jpg","galleries_id":409790,"server_id":1,"link":"photo_7560652.html","width":130,"caption":"","height":197});
															thumbnails[7560653] = clik.newPhoto({"id":7560653,"src":"DSC_3993-1_thumb.jpg","galleries_id":409790,"server_id":1,"link":"photo_7560653.html","width":130,"caption":"","height":85});
															thumbnails[7297563] = clik.newPhoto({"id":7297563,"src":"PA300168-1_thumb.jpg","galleries_id":49246,"server_id":1,"link":"photo_7297563.html","width":130,"caption":"","height":98});
															thumbnails[7607371] = clik.newPhoto({"id":7607371,"src":"cid_IMG_1210-1_thumb.jpg","galleries_id":49246,"server_id":1,"link":"photo_7607371.html","width":130,"caption":"","height":97});

/***************************************************************************
* Create the array of Gallery objects                                      *
***************************************************************************/
var galleries = new Object();
				  						galleries[49246] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Ist Team 2011","link":"gallery_49246.html","maxRecords":0.0,"photoIDs":[7297563.0,7607371.0],"skipIndex":0,"section_code":"gallery","featured_images":7297563.0,"id":49246,"singleSection":false});				  						galleries[49247] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"2nd Team 2011","link":"gallery_49247.html","maxRecords":0.0,"photoIDs":[7297548.0],"skipIndex":0,"section_code":"gallery","featured_images":7297548.0,"id":49247,"singleSection":false});				  						galleries[26665] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Carlton Park I v Lowestoft II.","link":"gallery_26665.html","maxRecords":0.0,"photoIDs":[646176.0,646179.0,646182.0,646189.0,646191.0,646193.0,646195.0,646196.0,646203.0,646205.0,646207.0,646211.0,646213.0,646215.0,646217.0,646221.0,646229.0,646233.0,646235.0,646236.0,646237.0,646238.0,646239.0],"skipIndex":0,"section_code":"gallery","featured_images":646221.0,"id":26665,"singleSection":false});				  						galleries[26670] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Carlton Park II v Grasshoppers II.","link":"gallery_26670.html","maxRecords":0.0,"photoIDs":[591772.0,591777.0,591778.0,591783.0,591784.0,591785.0,591788.0,591792.0,591796.0,591797.0,591800.0],"skipIndex":0,"section_code":"gallery","featured_images":591784.0,"id":26670,"singleSection":false});				  						galleries[136620] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Haverhill II v Carlton Park II.","link":"gallery_136620.html","maxRecords":0.0,"photoIDs":[2043220.0,2043221.0,2043222.0,2043223.0,2043226.0,2043227.0,2043228.0,2043229.0],"skipIndex":0,"section_code":"gallery","featured_images":2043220.0,"id":136620,"singleSection":false});				  						galleries[409790] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"U17's 2011","link":"gallery_409790.html","maxRecords":0.0,"photoIDs":[7560636.0,7560639.0,7560640.0,7560642.0,7560643.0,7560644.0,7560645.0,7560647.0,7560648.0,7560649.0,7560651.0,7560652.0,7560653.0],"skipIndex":0,"section_code":"gallery","featured_images":7560653.0,"id":409790,"singleSection":false});				  						galleries[50499] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Christmas Party.","link":"gallery_50499.html","maxRecords":0.0,"photoIDs":[1710021.0,1710023.0,1710024.0,1710026.0,1710029.0,1710030.0,1710033.0,1710035.0,1710039.0,1710040.0,1710041.0,1710042.0],"skipIndex":0,"section_code":"gallery","featured_images":1710023.0,"id":50499,"singleSection":false});/***************************************************************************
* Create the array of image sets                                           *
***************************************************************************/
var imageSets = {};
imageSets[1] = '646221,646196,646195,646189,591785,591777,321116';
imageSets[2] = '7560653,2043220,1710023,646221,646174,591793,591784,7297563';
imageSets[3] = '321116';
 /***************************************************************************
* Get a server path given an ID                                            *
***************************************************************************/
function getServerPath(server_id) {
	var val = -1;
		switch (server_id) {
		case 51:
		val = 'http://www12.clikpic.com/carltonpark/images';
		break;
	}
		switch (server_id) {
		case 0:
		val = 'http://www.clikpic.com/carltonpark/images';
		break;
	}
		switch (server_id) {
		case 1:
		val = 'http://www1.clikpic.com/carltonpark/images';
		break;
	}
		switch (server_id) {
		case 2:
		val = 'http://admin.clikpic.com/carltonpark/images';
		break;
	}
		switch (server_id) {
		case 24:
		val = 'http://tpc15/clikpic/carltonpark/images';
		break;
	}
		switch (server_id) {
		case 4:
		val = 'http://clikchurch.clikpic.com/carltonpark/images';
		break;
	}
		switch (server_id) {
		case 5:
		val = 'http://www2.clikpic.com/carltonpark/images';
		break;
	}
		switch (server_id) {
		case 22:
		val = 'http://tpc5/clikpic/carltonpark/images';
		break;
	}
		switch (server_id) {
		case 23:
		val = 'http://tpc10/clikpic/carltonpark/images';
		break;
	}
		switch (server_id) {
		case 25:
		val = 'http://tpc16/clikpic/carltonpark/images';
		break;
	}
		switch (server_id) {
		case 26:
		val = 'http://tpc20/clikpic/carltonpark/images';
		break;
	}
		switch (server_id) {
		case 40:
		val = 'http://www11.clikpic.com/carltonpark/images';
		break;
	}
		switch (server_id) {
		case 42:
		val = 'db2.clikpic.com/carltonpark/images';
		break;
	}
		switch (server_id) {
		case 15:
		val = 'http://www3.clikpic.com/carltonpark/images';
		break;
	}
		switch (server_id) {
		case 18:
		val = 'http://www4.clikpic.com/carltonpark/images';
		break;
	}
		switch (server_id) {
		case 19:
		val = 'http://www5.clikpic.com/carltonpark/images';
		break;
	}
		switch (server_id) {
		case 31:
		val = 'http://www7.clikpic.com/carltonpark/images';
		break;
	}
		switch (server_id) {
		case 32:
		val = 'http://www8.clikpic.com/carltonpark/images';
		break;
	}
		switch (server_id) {
		case 34:
		val = 'http://www9.clikpic.com/carltonpark/images';
		break;
	}
		switch (server_id) {
		case 35:
		val = 'http://admin3.clikpic.com/carltonpark/images';
		break;
	}
		switch (server_id) {
		case 37:
		val = 'http://admin4.clikpic.com/carltonpark/images';
		break;
	}
		switch (server_id) {
		case 38:
		val = 'http://admin5.clikpic.com/carltonpark/images';
		break;
	}
		switch (server_id) {
		case 39:
		val = 'http://www10.clikpic.com/carltonpark/images';
		break;
	}
		switch (server_id) {
		case 53:
		val = 'http://images.clikpic.com/carltonpark/images';
		break;
	}
		switch (server_id) {
		case 52:
		val = 'http://tpc22/clikpic/carltonpark/images';
		break;
	}
		switch (server_id) {
		case 21:
		val = 'http://www6.clikpic.com/carltonpark/images';
		break;
	}
		switch (server_id) {
		case 50:
		val = '[cliktext value=article.servers_id type=servers_id]/carltonpark/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 = 'Carlton Park Hockey Club FSC: ' + 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;
	}
}

			

