window.thumbnails = {};
															thumbnails[3471537] = clik.newPhoto({"id":3471537,"src":"DSCF0043_thumb.JPG","galleries_id":"","server_id":32,"link":"#","width":130,"caption":"","height":101});
															thumbnails[4967976] = clik.newPhoto({"id":4967976,"src":"DSCF0991_thumb.JPG","galleries_id":"","server_id":32,"link":"#","width":130,"caption":"Angharad","height":98});
															thumbnails[4991852] = clik.newPhoto({"id":4991852,"src":"DSCF1004_thumb.JPG","galleries_id":"","server_id":32,"link":"#","width":130,"caption":"Olivia","height":98});
															thumbnails[6200964] = clik.newPhoto({"id":6200964,"src":"DSCF1298_thumb.JPG","galleries_id":"","server_id":32,"link":"#","width":130,"caption":"","height":93});
															thumbnails[8782885] = clik.newPhoto({"id":8782885,"src":"DSCF2115_thumb.JPG","galleries_id":"","server_id":32,"link":"#","width":130,"caption":"","height":98});
															thumbnails[3458444] = clik.newPhoto({"id":3458444,"src":"DSCF0378_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_3458444.html","width":130,"caption":"Winter","height":92});
															thumbnails[3475643] = clik.newPhoto({"id":3475643,"src":"DSCF0392_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_3475643.html","width":130,"caption":"","height":85});
															thumbnails[3686010] = clik.newPhoto({"id":3686010,"src":"DSCF0546_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_3686010.html","width":130,"caption":"","height":91});
															thumbnails[3686060] = clik.newPhoto({"id":3686060,"src":"DSCF0548_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_3686060.html","width":130,"caption":"","height":86});
															thumbnails[3686082] = clik.newPhoto({"id":3686082,"src":"DSCF0552_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_3686082.html","width":130,"caption":"","height":86});
															thumbnails[3686091] = clik.newPhoto({"id":3686091,"src":"DSCF0553_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_3686091.html","width":130,"caption":"","height":86});
															thumbnails[3686093] = clik.newPhoto({"id":3686093,"src":"DSCF0554_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_3686093.html","width":130,"caption":"","height":86});
															thumbnails[3686111] = clik.newPhoto({"id":3686111,"src":"DSCF0556_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_3686111.html","width":130,"caption":"","height":86});
															thumbnails[3686209] = clik.newPhoto({"id":3686209,"src":"DSCF0558_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_3686209.html","width":130,"caption":"","height":86});
															thumbnails[3686255] = clik.newPhoto({"id":3686255,"src":"DSCF0561_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_3686255.html","width":130,"caption":"","height":86});
															thumbnails[3686345] = clik.newPhoto({"id":3686345,"src":"DSCF0563_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_3686345.html","width":130,"caption":"","height":86});
															thumbnails[3746062] = clik.newPhoto({"id":3746062,"src":"DSCF0616_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_3746062.html","width":130,"caption":"","height":96});
															thumbnails[3746075] = clik.newPhoto({"id":3746075,"src":"DSCF0619_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_3746075.html","width":130,"caption":"","height":92});
															thumbnails[4525893] = clik.newPhoto({"id":4525893,"src":"DSCF0880_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_4525893.html","width":130,"caption":"Heart button","height":92});
															thumbnails[4781926] = clik.newPhoto({"id":4781926,"src":"DSCF0907_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_4781926.html","width":130,"caption":"Turquoise & Lime Charm Set","height":98});
															thumbnails[4826223] = clik.newPhoto({"id":4826223,"src":"DSCF0917_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_4826223.html","width":130,"caption":"Nigella","height":98});
															thumbnails[4913376] = clik.newPhoto({"id":4913376,"src":"DSCF0941_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_4913376.html","width":130,"caption":"Stary Gazy Night II","height":98});
															thumbnails[4941277] = clik.newPhoto({"id":4941277,"src":"DSCF0971_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_4941277.html","width":130,"caption":"Rubina","height":98});
															thumbnails[4941501] = clik.newPhoto({"id":4941501,"src":"DSCF0977_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_4941501.html","width":130,"caption":"Scarlet O'Hara ","height":98});
															thumbnails[4967965] = clik.newPhoto({"id":4967965,"src":"DSCF0996_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_4967965.html","width":130,"caption":"Honey","height":98});
															thumbnails[5073027] = clik.newPhoto({"id":5073027,"src":"DSCF1012_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_5073027.html","width":130,"caption":"Heather","height":98});
															thumbnails[5073118] = clik.newPhoto({"id":5073118,"src":"DSCF1016_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_5073118.html","width":130,"caption":"Olivia","height":98});
															thumbnails[5086161] = clik.newPhoto({"id":5086161,"src":"DSCF1022_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_5086161.html","width":130,"caption":"Honey drizzle earrings","height":96});
															thumbnails[5086164] = clik.newPhoto({"id":5086164,"src":"DSCF1050_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_5086164.html","width":130,"caption":"Melanie","height":98});
															thumbnails[5086166] = clik.newPhoto({"id":5086166,"src":"DSCF1042_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_5086166.html","width":130,"caption":"Rosa","height":96});
															thumbnails[5086170] = clik.newPhoto({"id":5086170,"src":"DSCF1031_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_5086170.html","width":130,"caption":"canyon","height":96});
															thumbnails[5088217] = clik.newPhoto({"id":5088217,"src":"DSCF1061_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_5088217.html","width":130,"caption":"Savannah","height":96});
															thumbnails[5090264] = clik.newPhoto({"id":5090264,"src":"DSCF1065_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_5090264.html","width":130,"caption":"","height":94});
															thumbnails[5090280] = clik.newPhoto({"id":5090280,"src":"DSCF1067_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_5090280.html","width":130,"caption":"","height":96});
															thumbnails[5090379] = clik.newPhoto({"id":5090379,"src":"DSCF1069_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_5090379.html","width":130,"caption":"","height":98});
															thumbnails[5191754] = clik.newPhoto({"id":5191754,"src":"DSCF1092_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_5191754.html","width":130,"caption":"Twilight  ","height":98});
															thumbnails[5211503] = clik.newPhoto({"id":5211503,"src":"DSCF1097_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_5211503.html","width":130,"caption":"Tobias & the Angel","height":93});
															thumbnails[5211589] = clik.newPhoto({"id":5211589,"src":"DSCF1112_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_5211589.html","width":130,"caption":"Blue Moon","height":98});
															thumbnails[5620648] = clik.newPhoto({"id":5620648,"src":"DSCF1169_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_5620648.html","width":130,"caption":"Snake Eyes","height":98});
															thumbnails[5620677] = clik.newPhoto({"id":5620677,"src":"DSCF1167_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_5620677.html","width":130,"caption":"Orchard","height":98});
															thumbnails[5811482] = clik.newPhoto({"id":5811482,"src":"DSCF1170_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_5811482.html","width":130,"caption":"Wing","height":93});
															thumbnails[6015234] = clik.newPhoto({"id":6015234,"src":"DSCF1243_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_6015234.html","width":130,"caption":"Penny","height":98});
															thumbnails[6142366] = clik.newPhoto({"id":6142366,"src":"DSCF1259_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_6142366.html","width":130,"caption":"Coast ","height":98});
															thumbnails[6142368] = clik.newPhoto({"id":6142368,"src":"DSCF1286_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_6142368.html","width":130,"caption":"","height":98});
															thumbnails[6142370] = clik.newPhoto({"id":6142370,"src":"DSCF1268_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_6142370.html","width":130,"caption":"Oceana","height":98});
															thumbnails[6142371] = clik.newPhoto({"id":6142371,"src":"DSCF1271_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_6142371.html","width":130,"caption":"Savana","height":96});
															thumbnails[6142373] = clik.newPhoto({"id":6142373,"src":"DSCF1273_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_6142373.html","width":130,"caption":"Helta-Skelta","height":98});
															thumbnails[6142380] = clik.newPhoto({"id":6142380,"src":"DSCF1254_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_6142380.html","width":130,"caption":"Fran - Sold ","height":96});
															thumbnails[6142381] = clik.newPhoto({"id":6142381,"src":"DSCF1255_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_6142381.html","width":130,"caption":"Martha - Sold","height":98});
															thumbnails[6167170] = clik.newPhoto({"id":6167170,"src":"DSCF1287_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_6167170.html","width":130,"caption":"Over the Rainbow","height":98});
															thumbnails[6167185] = clik.newPhoto({"id":6167185,"src":"DSCF1284_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_6167185.html","width":130,"caption":"Kath's Dream","height":98});
															thumbnails[6177304] = clik.newPhoto({"id":6177304,"src":"DSCF1295_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_6177304.html","width":130,"caption":"Let's do the twist","height":98});
															thumbnails[7075627] = clik.newPhoto({"id":7075627,"src":"lunar_bud_thumb.jpg","galleries_id":206972,"server_id":32,"link":"photo_7075627.html","width":130,"caption":"Lunar Bud","height":98});
															thumbnails[7075705] = clik.newPhoto({"id":7075705,"src":"Roos_Garden_thumb.jpg","galleries_id":206972,"server_id":32,"link":"photo_7075705.html","width":130,"caption":"My Garden","height":98});
															thumbnails[7075798] = clik.newPhoto({"id":7075798,"src":"Ariana_thumb.jpg","galleries_id":206972,"server_id":32,"link":"photo_7075798.html","width":130,"caption":"Ariana","height":98});
															thumbnails[7075843] = clik.newPhoto({"id":7075843,"src":"Snapshot1_thumb.jpg","galleries_id":185614,"server_id":32,"link":"photo_7075843.html","width":130,"caption":"Snap Shot","height":91});
															thumbnails[7075985] = clik.newPhoto({"id":7075985,"src":"Love_thumb.jpg","galleries_id":206972,"server_id":32,"link":"photo_7075985.html","width":130,"caption":"Love","height":98});
															thumbnails[7076113] = clik.newPhoto({"id":7076113,"src":"Miss_Bennett_Pink1_thumb.jpg","galleries_id":206972,"server_id":32,"link":"photo_7076113.html","width":130,"caption":"Miss Bennett Pink","height":98});
															thumbnails[7076254] = clik.newPhoto({"id":7076254,"src":"Water_lily_thumb.jpg","galleries_id":185615,"server_id":32,"link":"photo_7076254.html","width":130,"caption":"Water Lily","height":98});
															thumbnails[7076539] = clik.newPhoto({"id":7076539,"src":"Buttonpage_thumb.jpg","galleries_id":187785,"server_id":32,"link":"photo_7076539.html","width":130,"caption":"Coming oon!","height":91});
															thumbnails[8099701] = clik.newPhoto({"id":8099701,"src":"DSCF1212_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_8099701.html","width":130,"caption":"","height":89});
															thumbnails[8782886] = clik.newPhoto({"id":8782886,"src":"DSCF2173_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_8782886.html","width":130,"caption":"","height":98});
															thumbnails[8902486] = clik.newPhoto({"id":8902486,"src":"DSCF2300_thumb.JPG","galleries_id":185614,"server_id":32,"link":"photo_8902486.html","width":130,"caption":"Cavern Pearls","height":98});
															thumbnails[4913357] = clik.newPhoto({"id":4913357,"src":"DSCF0935_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_4913357.html","width":130,"caption":"Mardi Gras","height":93});
															thumbnails[5620679] = clik.newPhoto({"id":5620679,"src":"DSCF1139_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_5620679.html","width":130,"caption":"","height":95});
															thumbnails[5090238] = clik.newPhoto({"id":5090238,"src":"DSCF1064_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_5090238.html","width":130,"caption":"","height":98});
															thumbnails[5090271] = clik.newPhoto({"id":5090271,"src":"DSCF1066_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_5090271.html","width":130,"caption":"","height":98});
															thumbnails[5090424] = clik.newPhoto({"id":5090424,"src":"DSCF1070_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_5090424.html","width":130,"caption":"","height":96});
															thumbnails[5090433] = clik.newPhoto({"id":5090433,"src":"DSCF1071_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_5090433.html","width":130,"caption":"","height":96});
															thumbnails[5090283] = clik.newPhoto({"id":5090283,"src":"DSCF1068_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_5090283.html","width":130,"caption":"","height":96});
															thumbnails[3686240] = clik.newPhoto({"id":3686240,"src":"DSCF0559_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_3686240.html","width":130,"caption":"","height":86});
															thumbnails[3475641] = clik.newPhoto({"id":3475641,"src":"DSCF0393_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_3475641.html","width":130,"caption":"","height":85});
															thumbnails[4942158] = clik.newPhoto({"id":4942158,"src":"DSCF0982_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_4942158.html","width":130,"caption":"Lily II","height":98});
															thumbnails[3999595] = clik.newPhoto({"id":3999595,"src":"DSCF0712_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_3999595.html","width":130,"caption":"Red Cavern","height":98});
															thumbnails[4765088] = clik.newPhoto({"id":4765088,"src":"DSCF0894_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_4765088.html","width":130,"caption":"Cherry & Ivory Charm Set -<br>\r\nSold thanks!","height":98});
															thumbnails[4913353] = clik.newPhoto({"id":4913353,"src":"DSCF0947_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_4913353.html","width":130,"caption":"Lily","height":98});
															thumbnails[4941489] = clik.newPhoto({"id":4941489,"src":"DSCF0975_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_4941489.html","width":130,"caption":"","height":98});
															thumbnails[5086103] = clik.newPhoto({"id":5086103,"src":"DSCF1033_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_5086103.html","width":130,"caption":"Theresa","height":96});
															thumbnails[4913339] = clik.newPhoto({"id":4913339,"src":"DSCF0944_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_4913339.html","width":130,"caption":"Very Berry","height":98});
															thumbnails[4826122] = clik.newPhoto({"id":4826122,"src":"DSCF0911_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_4826122.html","width":130,"caption":"Tempest  - Sold, thanks!","height":98});
															thumbnails[4732287] = clik.newPhoto({"id":4732287,"src":"DSCF0882_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_4732287.html","width":130,"caption":"Stary Gazy Night - <br>\r\nSold thanks!","height":98});
															thumbnails[4732379] = clik.newPhoto({"id":4732379,"src":"DSCF0879_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_4732379.html","width":130,"caption":"","height":98});
															thumbnails[3783488] = clik.newPhoto({"id":3783488,"src":"DSCF0623_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_3783488.html","width":130,"caption":"Juliette","height":98});
															thumbnails[3783594] = clik.newPhoto({"id":3783594,"src":"DSCF0632_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_3783594.html","width":130,"caption":"Fete","height":98});
															thumbnails[3499298] = clik.newPhoto({"id":3499298,"src":"DSCF0602_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_3499298.html","width":130,"caption":"Chrysalis  <br>\r\n","height":93});
															thumbnails[3604513] = clik.newPhoto({"id":3604513,"src":"turq-spot-btn-corsage_thumb.jpg","galleries_id":206972,"server_id":32,"link":"photo_3604513.html","width":130,"caption":"Angel Lodge Studio","height":98});
															thumbnails[4342440] = clik.newPhoto({"id":4342440,"src":"DSCF0870_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_4342440.html","width":130,"caption":"Cavern pearls","height":98});
															thumbnails[3600333] = clik.newPhoto({"id":3600333,"src":"handmade_by_m_1_005_2_thumb.jpg","galleries_id":206972,"server_id":32,"link":"photo_3600333.html","width":130,"caption":"Marianne O'Malley","height":98});
															thumbnails[3606297] = clik.newPhoto({"id":3606297,"src":"DSCF0475_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_3606297.html","width":130,"caption":"Pumpkin","height":91});
															thumbnails[3408007] = clik.newPhoto({"id":3408007,"src":"DSCF0510_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_3408007.html","width":130,"caption":"Emma ","height":98});
															thumbnails[3744192] = clik.newPhoto({"id":3744192,"src":"DSCF05871_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_3744192.html","width":130,"caption":"Loire","height":98});
															thumbnails[3607108] = clik.newPhoto({"id":3607108,"src":"DSCF0482_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_3607108.html","width":130,"caption":"Pixie","height":94});
															thumbnails[3861388] = clik.newPhoto({"id":3861388,"src":"DSCF0637_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_3861388.html","width":130,"caption":"Cerrig y Graig ","height":98});
															thumbnails[3600331] = clik.newPhoto({"id":3600331,"src":"handmade_by_M_1_003_2_thumb.jpg","galleries_id":206972,"server_id":32,"link":"photo_3600331.html","width":130,"caption":"Marianne O'Malley","height":90});
															thumbnails[3607141] = clik.newPhoto({"id":3607141,"src":"DSCF0540_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_3607141.html","width":130,"caption":"Emily","height":94});
															thumbnails[3793883] = clik.newPhoto({"id":3793883,"src":"DSCF0636_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_3793883.html","width":130,"caption":"Marianne O'Malley","height":91});
															thumbnails[3607092] = clik.newPhoto({"id":3607092,"src":"DSCF0483_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_3607092.html","width":130,"caption":"Willow II","height":98});
															thumbnails[3467841] = clik.newPhoto({"id":3467841,"src":"DSCF0054_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_3467841.html","width":130,"caption":"","height":99});
															thumbnails[3604512] = clik.newPhoto({"id":3604512,"src":"corsage-red-spotty_charms-btn-copy_thumb.jpg","galleries_id":206972,"server_id":32,"link":"photo_3604512.html","width":130,"caption":"Angel Lodge Studio","height":98});
															thumbnails[3408050] = clik.newPhoto({"id":3408050,"src":"DSCF0513_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_3408050.html","width":130,"caption":"Kate ","height":98});
															thumbnails[3686051] = clik.newPhoto({"id":3686051,"src":"DSCF0547_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_3686051.html","width":130,"caption":"","height":88});
															thumbnails[3733154] = clik.newPhoto({"id":3733154,"src":"DSCF0609_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_3733154.html","width":130,"caption":"Cherry Bomb","height":93});
															thumbnails[3573599] = clik.newPhoto({"id":3573599,"src":"DSCF0449_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_3573599.html","width":130,"caption":"Willow","height":93});
															thumbnails[3613387] = clik.newPhoto({"id":3613387,"src":"Picture_thumb.jpg","galleries_id":206972,"server_id":32,"link":"photo_3613387.html","width":130,"caption":"Surf","height":94});
															thumbnails[3467772] = clik.newPhoto({"id":3467772,"src":"DSCF0374_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_3467772.html","width":130,"caption":"Galactica","height":98});
															thumbnails[3553799] = clik.newPhoto({"id":3553799,"src":"DSCF0443_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_3553799.html","width":130,"caption":"Seascape","height":98});
															thumbnails[3467791] = clik.newPhoto({"id":3467791,"src":"DSCF0375_thumb.JPG","galleries_id":206972,"server_id":32,"link":"photo_3467791.html","width":130,"caption":"Cosmos","height":108});

/***************************************************************************
* Create the array of Gallery objects                                      *
***************************************************************************/
var galleries = new Object();
				  						galleries[185614] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Sets","link":"gallery_185614.html","maxRecords":0.0,"photoIDs":[7075843.0,8902486.0],"skipIndex":0,"section_code":"gallery","featured_images":"8902486,7075843","id":185614,"singleSection":false});				  						galleries[185615] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Focals","link":"gallery_185615.html","maxRecords":0.0,"photoIDs":[7076254.0],"skipIndex":0,"section_code":"gallery","featured_images":7076254.0,"id":185615,"singleSection":false});				  						galleries[187785] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Buttons","link":"gallery_187785.html","maxRecords":0.0,"photoIDs":[7076539.0],"skipIndex":0,"section_code":"gallery","featured_images":7076539.0,"id":187785,"singleSection":false});				  						galleries[206972] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Gallery","link":"gallery_206972.html","maxRecords":0.0,"photoIDs":[3458444.0,3475643.0,3686010.0,3686060.0,3686082.0,3686091.0,3686093.0,3686111.0,3686209.0,3686255.0,3686345.0,3746062.0,3746075.0,4525893.0,4781926.0,4826223.0,4913376.0,4941277.0,4941501.0,4967965.0,5073027.0,5073118.0,5086161.0,5086164.0,5086166.0,5086170.0,5088217.0,5090264.0,5090280.0,5090379.0,5191754.0,5211503.0,5211589.0,5620648.0,5620677.0,5811482.0,6015234.0,6142366.0,6142368.0,6142370.0,6142371.0,6142373.0,6142380.0,6142381.0,6167170.0,6167185.0,6177304.0,7075627.0,7075705.0,7075798.0,7075985.0,7076113.0,8099701.0,8782886.0,4913357.0,5620679.0,5090238.0,5090271.0,5090424.0,5090433.0,5090283.0,3686240.0,3475641.0,4942158.0,3999595.0,4765088.0,4913353.0,4941489.0,5086103.0,4913339.0,4826122.0,4732287.0,4732379.0,3783488.0,3783594.0,3499298.0,3604513.0,4342440.0,3600333.0,3606297.0,3408007.0,3744192.0,3607108.0,3861388.0,3600331.0,3607141.0,3793883.0,3607092.0,3467841.0,3604512.0,3408050.0,3686051.0,3733154.0,3573599.0,3613387.0,3467772.0,3553799.0,3467791.0],"skipIndex":0,"section_code":"gallery","featured_images":"7076113,7075627,6167170,6142371,6142368,6015234,5620679,5620648,4941489,4941277,4826122,4765088,4525893,3686010,3499298,3467841","id":206972,"singleSection":false});/***************************************************************************
* Create the array of image sets                                           *
***************************************************************************/
var imageSets = {};
imageSets[1] = '8902486,8782886,8782885,7075627,4941277,5620679';
imageSets[2] = '7076539,7076113,7075627,6167170,6142371,6142368,6015234,5620648,4967976,4941277,4525893,3686010,3471537,5620679,4765088,4941489,4826122,3499298,3467841';
imageSets[3] = '8902486,8782886,8782885,8099701,7076539,7076254,7076113,7075985,7075843,7075798,7075705,7075627,6200964,6177304,6167185,6167170,6142381,6142380,6142373,6142371,6142370,6142368,6142366,6015234,5811482,5620679,5620677,5620648,5211589,5211503,5191754,5090433,5090424,5090379,5090283,5090280,5090271,5090264,5090238,5088217,5086170,5086166,5086164,5086161,5086103,5073118,5073027,4991852,4967976,4967965';
 /***************************************************************************
* Get a server path given an ID                                            *
***************************************************************************/
function getServerPath(server_id) {
	var val = -1;
		switch (server_id) {
		case 51:
		val = 'http://www12.clikpic.com/Roowelch1/images';
		break;
	}
		switch (server_id) {
		case 0:
		val = 'http://www.clikpic.com/Roowelch1/images';
		break;
	}
		switch (server_id) {
		case 1:
		val = 'http://www1.clikpic.com/Roowelch1/images';
		break;
	}
		switch (server_id) {
		case 2:
		val = 'http://admin.clikpic.com/Roowelch1/images';
		break;
	}
		switch (server_id) {
		case 24:
		val = 'http://tpc15/clikpic/Roowelch1/images';
		break;
	}
		switch (server_id) {
		case 4:
		val = 'http://clikchurch.clikpic.com/Roowelch1/images';
		break;
	}
		switch (server_id) {
		case 5:
		val = 'http://www2.clikpic.com/Roowelch1/images';
		break;
	}
		switch (server_id) {
		case 22:
		val = 'http://tpc5/clikpic/Roowelch1/images';
		break;
	}
		switch (server_id) {
		case 23:
		val = 'http://tpc10/clikpic/Roowelch1/images';
		break;
	}
		switch (server_id) {
		case 25:
		val = 'http://tpc16/clikpic/Roowelch1/images';
		break;
	}
		switch (server_id) {
		case 26:
		val = 'http://tpc20/clikpic/Roowelch1/images';
		break;
	}
		switch (server_id) {
		case 40:
		val = 'http://www11.clikpic.com/Roowelch1/images';
		break;
	}
		switch (server_id) {
		case 42:
		val = 'db2.clikpic.com/Roowelch1/images';
		break;
	}
		switch (server_id) {
		case 15:
		val = 'http://www3.clikpic.com/Roowelch1/images';
		break;
	}
		switch (server_id) {
		case 18:
		val = 'http://www4.clikpic.com/Roowelch1/images';
		break;
	}
		switch (server_id) {
		case 19:
		val = 'http://www5.clikpic.com/Roowelch1/images';
		break;
	}
		switch (server_id) {
		case 31:
		val = 'http://www7.clikpic.com/Roowelch1/images';
		break;
	}
		switch (server_id) {
		case 32:
		val = 'http://www8.clikpic.com/Roowelch1/images';
		break;
	}
		switch (server_id) {
		case 34:
		val = 'http://www9.clikpic.com/Roowelch1/images';
		break;
	}
		switch (server_id) {
		case 35:
		val = 'http://admin3.clikpic.com/Roowelch1/images';
		break;
	}
		switch (server_id) {
		case 37:
		val = 'http://admin4.clikpic.com/Roowelch1/images';
		break;
	}
		switch (server_id) {
		case 38:
		val = 'http://admin5.clikpic.com/Roowelch1/images';
		break;
	}
		switch (server_id) {
		case 39:
		val = 'http://www10.clikpic.com/Roowelch1/images';
		break;
	}
		switch (server_id) {
		case 53:
		val = 'http://images.clikpic.com/Roowelch1/images';
		break;
	}
		switch (server_id) {
		case 52:
		val = 'http://tpc22/clikpic/Roowelch1/images';
		break;
	}
		switch (server_id) {
		case 21:
		val = 'http://www6.clikpic.com/Roowelch1/images';
		break;
	}
		switch (server_id) {
		case 50:
		val = '[cliktext value=article.servers_id type=servers_id]/Roowelch1/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 = 'Roo Welch Glass Artist: ' + 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>';
	}
				
	temp += this.fnGetPaymentInfo();
				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>Buy now using PayPal:</p>';
				temp += '<div class="imageinfo" id="imagePrice"><strong>' + this.purchase_instruction + '</strong> &pound;' + (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 += '<form id="paymentForm" style="margin:0px;border:0px;" name="paymentForm">';
			temp += '	<input type="hidden" name="item_option" value="' + item_option + '">';
			temp += '	<input type="hidden" name="site" value="ROOWELCH1">';
			temp += '	<input type="hidden" name="item_number" value="'+ this.id +'">';
			temp += '	<input type="hidden" name="quantity" value="1">';
						temp += '	<input value="Add to cart" id="paymentAddButton" class="button" onmouseover="this.className=\'buttonHi\'\;" onmouseout="this.className=\'button\'\;" type="Button">';
							temp += '	<input value="View cart" id="paymentViewButton" class="button" onmouseover="this.className=\'buttonHi\';" onmouseout="this.className=\'button\';" type="Button" onclick="javascript:window.location=\'cart.html\'">';
			temp += '</form>';
						temp += '<div class="clearing">&nbsp;</div>';
			temp += '<div id="confirmContainer">';
			temp += '<div id="paymentConfirm">Item added to cart</div>';
			temp += '</div>';
			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;
	}
}

			

