window.thumbnails = {};
															thumbnails[4128778] = clik.newPhoto({"id":4128778,"src":"P91002691_thumb.jpg","galleries_id":"","server_id":32,"link":"#","width":130,"caption":"","height":98});
															thumbnails[4128782] = clik.newPhoto({"id":4128782,"src":"PA1507211_thumb.jpg","galleries_id":"","server_id":32,"link":"#","width":130,"caption":"","height":98});
															thumbnails[5985270] = clik.newPhoto({"id":5985270,"src":"Georgian_Fair193_thumb.jpg","galleries_id":"","server_id":32,"link":"#","width":130,"caption":"Setting the Scene","height":98});
															thumbnails[5985266] = clik.newPhoto({"id":5985266,"src":"Georgian_Fair012_thumb.jpg","galleries_id":"","server_id":32,"link":"#","width":130,"caption":"Georgian Gentleman","height":171});
															thumbnails[5985273] = clik.newPhoto({"id":5985273,"src":"Georgian_Fair176_thumb.jpg","galleries_id":"","server_id":32,"link":"#","width":130,"caption":"Georgian Doorway","height":108});
															thumbnails[5985276] = clik.newPhoto({"id":5985276,"src":"Georgian_Fair084_thumb.jpg","galleries_id":"","server_id":32,"link":"#","width":130,"caption":"The Mayor","height":173});
															thumbnails[5985282] = clik.newPhoto({"id":5985282,"src":"Georgian_Fair110_thumb.jpg","galleries_id":"","server_id":32,"link":"#","width":130,"caption":"The Lady of the House","height":94});
															thumbnails[5985278] = clik.newPhoto({"id":5985278,"src":"Georgian_Fair173_thumb.jpg","galleries_id":"","server_id":32,"link":"#","width":130,"caption":"Georgian Square","height":173});
															thumbnails[5985289] = clik.newPhoto({"id":5985289,"src":"Georgian_Fair130_thumb.jpg","galleries_id":"","server_id":32,"link":"#","width":130,"caption":"Street Entertainer","height":111});
															thumbnails[5985293] = clik.newPhoto({"id":5985293,"src":"Georgian_Fair183_thumb.jpg","galleries_id":"","server_id":32,"link":"#","width":130,"caption":"Georgian Yard","height":204});
															thumbnails[5985285] = clik.newPhoto({"id":5985285,"src":"Georgian_Fair140_thumb.jpg","galleries_id":"","server_id":32,"link":"#","width":130,"caption":"At the Pub","height":133});
															thumbnails[5985295] = clik.newPhoto({"id":5985295,"src":"Georgian_Fair144_thumb.jpg","galleries_id":"","server_id":32,"link":"#","width":130,"caption":"In the Crowd","height":173});
															thumbnails[5985299] = clik.newPhoto({"id":5985299,"src":"Georgian_Fair094_thumb.jpg","galleries_id":"","server_id":32,"link":"#","width":130,"caption":"The Piper","height":98});
															thumbnails[5985304] = clik.newPhoto({"id":5985304,"src":"Georgian_Fair146_thumb.jpg","galleries_id":"","server_id":32,"link":"#","width":130,"caption":"A Military Salute","height":98});
															thumbnails[4727241] = clik.newPhoto({"id":4727241,"src":"P8181834_thumb.jpg","galleries_id":271401,"server_id":32,"link":"photo_4727241.html","width":130,"caption":"Lamb stew at a roadside cafe near Godafoss","height":173});
															thumbnails[4735070] = clik.newPhoto({"id":4735070,"src":"P8191962_thumb.jpg","galleries_id":271401,"server_id":32,"link":"photo_4735070.html","width":130,"caption":"Thermal area, Myvatn","height":173});
															thumbnails[4735072] = clik.newPhoto({"id":4735072,"src":"P8202074_thumb.jpg","galleries_id":271401,"server_id":32,"link":"photo_4735072.html","width":130,"caption":"Lava formation, Hofdi gardens, Lake Myvatn","height":98});
															thumbnails[4735074] = clik.newPhoto({"id":4735074,"src":"P8202135_thumb.jpg","galleries_id":271401,"server_id":32,"link":"photo_4735074.html","width":130,"caption":"Dettifoss, on a rather overcast afternoon","height":98});
															thumbnails[4735076] = clik.newPhoto({"id":4735076,"src":"P8212228_thumb.jpg","galleries_id":271401,"server_id":32,"link":"photo_4735076.html","width":130,"caption":"Seydisfjordur","height":98});
															thumbnails[4735080] = clik.newPhoto({"id":4735080,"src":"P8212289_thumb.jpg","galleries_id":271401,"server_id":32,"link":"photo_4735080.html","width":130,"caption":"Icelandic Church, Breidalsvik","height":98});
															thumbnails[4735082] = clik.newPhoto({"id":4735082,"src":"P8222385_thumb.jpg","galleries_id":271401,"server_id":32,"link":"photo_4735082.html","width":130,"caption":"The N1 through fjordland, SE Iceland","height":98});
															thumbnails[4735089] = clik.newPhoto({"id":4735089,"src":"P8222429_thumb.jpg","galleries_id":271401,"server_id":32,"link":"photo_4735089.html","width":130,"caption":"","height":98});
															thumbnails[4735090] = clik.newPhoto({"id":4735090,"src":"P8232528_thumb.jpg","galleries_id":271401,"server_id":32,"link":"photo_4735090.html","width":130,"caption":"Close-up of ice at Jokulsarlon. The blue-green colours vary with the age and purity of the ice","height":98});
															thumbnails[4735094] = clik.newPhoto({"id":4735094,"src":"P8232573_thumb.jpg","galleries_id":271401,"server_id":32,"link":"photo_4735094.html","width":130,"caption":"Flower head at Svartifoss.","height":98});
															thumbnails[4735099] = clik.newPhoto({"id":4735099,"src":"P8252651_thumb.jpg","galleries_id":271401,"server_id":32,"link":"photo_4735099.html","width":130,"caption":"Un-named waterfall and Icelandic farmhouse","height":98});
															thumbnails[4735104] = clik.newPhoto({"id":4735104,"src":"P8252751_thumb.jpg","galleries_id":271401,"server_id":32,"link":"photo_4735104.html","width":130,"caption":"Pen and inkwell in the school house at the Skogar Folk Museum","height":173});
															thumbnails[4735113] = clik.newPhoto({"id":4735113,"src":"P8252766_thumb.jpg","galleries_id":271401,"server_id":32,"link":"photo_4735113.html","width":130,"caption":"Skogarfoss - adjacent to the Skogar Folk museum.","height":98});
															thumbnails[4735116] = clik.newPhoto({"id":4735116,"src":"P8273017_thumb.jpg","galleries_id":271401,"server_id":32,"link":"photo_4735116.html","width":130,"caption":"Stokkur geysir erupting, as it does every 3-7 minutes","height":98});
															thumbnails[4735119] = clik.newPhoto({"id":4735119,"src":"P8283181_thumb.jpg","galleries_id":271401,"server_id":32,"link":"photo_4735119.html","width":130,"caption":"Fishing boat exhibit, Keflavik sea front","height":173});
															thumbnails[5637441] = clik.newPhoto({"id":5637441,"src":"P3133695_thumb.jpg","galleries_id":173891,"server_id":32,"link":"photo_5637441.html","width":130,"caption":"","height":173});
															thumbnails[5637452] = clik.newPhoto({"id":5637452,"src":"P3133696_thumb.jpg","galleries_id":173891,"server_id":32,"link":"photo_5637452.html","width":130,"caption":"","height":98});
															thumbnails[5637445] = clik.newPhoto({"id":5637445,"src":"P3133703_thumb.jpg","galleries_id":173891,"server_id":32,"link":"photo_5637445.html","width":130,"caption":"","height":173});
															thumbnails[5637449] = clik.newPhoto({"id":5637449,"src":"P3133704_thumb.jpg","galleries_id":173891,"server_id":32,"link":"photo_5637449.html","width":130,"caption":"","height":98});
															thumbnails[5637454] = clik.newPhoto({"id":5637454,"src":"P3133698_thumb.jpg","galleries_id":173891,"server_id":32,"link":"photo_5637454.html","width":130,"caption":"","height":173});
															thumbnails[2775350] = clik.newPhoto({"id":2775350,"src":"2005-01-29 12-31-423_thumb.jpg","galleries_id":173891,"server_id":32,"link":"photo_2775350.html","width":130,"caption":"Whitehaven Harbour","height":173});
															thumbnails[2775369] = clik.newPhoto({"id":2775369,"src":"P21065543_thumb.jpg","galleries_id":173892,"server_id":32,"link":"photo_2775369.html","width":130,"caption":"","height":173});
															thumbnails[2776447] = clik.newPhoto({"id":2776447,"src":"PA280920s_thumb.jpg","galleries_id":173980,"server_id":32,"link":"photo_2776447.html","width":130,"caption":"Radstock, Somerset","height":98});
															thumbnails[4128795] = clik.newPhoto({"id":4128795,"src":"PB3097351_thumb.jpg","galleries_id":287182,"server_id":32,"link":"photo_4128795.html","width":130,"caption":"The Wave. Marport","height":96});
															thumbnails[7193358] = clik.newPhoto({"id":7193358,"src":"Australia04-518_thumb.jpg","galleries_id":173890,"server_id":32,"link":"photo_7193358.html","width":130,"caption":"Uluru, Northern Territories, Australia","height":98});
															thumbnails[2775351] = clik.newPhoto({"id":2775351,"src":"2005-03-20 11-27-473_thumb.jpg","galleries_id":173891,"server_id":32,"link":"photo_2775351.html","width":130,"caption":"Silloth","height":98});
															thumbnails[2775358] = clik.newPhoto({"id":2775358,"src":"Australia04-2353_thumb.jpg","galleries_id":173890,"server_id":32,"link":"photo_2775358.html","width":130,"caption":"Melbourne Arts Centre","height":173});
															thumbnails[2775367] = clik.newPhoto({"id":2775367,"src":"P11364003_thumb.jpg","galleries_id":173892,"server_id":32,"link":"photo_2775367.html","width":130,"caption":"","height":98});
															thumbnails[2777160] = clik.newPhoto({"id":2777160,"src":"P5318101_thumb.jpg","galleries_id":173980,"server_id":32,"link":"photo_2777160.html","width":130,"caption":"","height":98});
															thumbnails[4128758] = clik.newPhoto({"id":4128758,"src":"P42606701_thumb.jpg","galleries_id":287182,"server_id":32,"link":"photo_4128758.html","width":130,"caption":"Skip - Solway Industrial Estate","height":173});
															thumbnails[2775353] = clik.newPhoto({"id":2775353,"src":"2005-04-06 16-27-553_thumb.jpg","galleries_id":173891,"server_id":32,"link":"photo_2775353.html","width":130,"caption":"Boltongate Church, Boltongate","height":173});
															thumbnails[2775356] = clik.newPhoto({"id":2775356,"src":"Australia04-373_thumb.jpg","galleries_id":173890,"server_id":32,"link":"photo_2775356.html","width":130,"caption":"Sydney Opera House","height":98});
															thumbnails[2775397] = clik.newPhoto({"id":2775397,"src":"Pink and greena_filtered_thumb.jpg","galleries_id":173892,"server_id":32,"link":"photo_2775397.html","width":130,"caption":"","height":98});
															thumbnails[2777208] = clik.newPhoto({"id":2777208,"src":"P1266456_thumb.jpg","galleries_id":173980,"server_id":32,"link":"photo_2777208.html","width":130,"caption":"Beaumaris Castle, Anglesey","height":173});
															thumbnails[4128794] = clik.newPhoto({"id":4128794,"src":"PB3097171_thumb.jpg","galleries_id":287182,"server_id":32,"link":"photo_4128794.html","width":130,"caption":"","height":98});
															thumbnails[2775360] = clik.newPhoto({"id":2775360,"src":"Australia04-6701_thumb.jpg","galleries_id":173890,"server_id":32,"link":"photo_2775360.html","width":130,"caption":"Northern Territory, Australia","height":173});
															thumbnails[2775370] = clik.newPhoto({"id":2775370,"src":"P2166559_thumb.ORF3.jpg","galleries_id":173891,"server_id":32,"link":"photo_2775370.html","width":130,"caption":"From Castle Crag","height":98});
															thumbnails[2775372] = clik.newPhoto({"id":2775372,"src":"P33073514_thumb.jpg","galleries_id":173892,"server_id":32,"link":"photo_2775372.html","width":130,"caption":"","height":98});
															thumbnails[2777203] = clik.newPhoto({"id":2777203,"src":"P1266485_thumb.jpg","galleries_id":173980,"server_id":32,"link":"photo_2777203.html","width":130,"caption":"Mynydd Parys, Anglesey","height":98});
															thumbnails[4128770] = clik.newPhoto({"id":4128770,"src":"P52408401_thumb.jpg","galleries_id":287182,"server_id":32,"link":"photo_4128770.html","width":130,"caption":"","height":173});
															thumbnails[2775354] = clik.newPhoto({"id":2775354,"src":"2005-05-02 12-49-453_thumb.jpg","galleries_id":173891,"server_id":32,"link":"photo_2775354.html","width":130,"caption":"Newlands Valley, from Catbells","height":173});
															thumbnails[2775385] = clik.newPhoto({"id":2775385,"src":"P9095750_thumb.jpg","galleries_id":173892,"server_id":32,"link":"photo_2775385.html","width":130,"caption":"","height":173});
															thumbnails[2776244] = clik.newPhoto({"id":2776244,"src":"Australia04-886_thumb.JPG","galleries_id":173890,"server_id":32,"link":"photo_2776244.html","width":130,"caption":"Yorkie's Knob, Queensland","height":98});
															thumbnails[2777169] = clik.newPhoto({"id":2777169,"src":"PC282512_thumb.ORF.jpg","galleries_id":173980,"server_id":32,"link":"photo_2777169.html","width":130,"caption":"Blackpool Pier","height":98});
															thumbnails[4128793] = clik.newPhoto({"id":4128793,"src":"PB3097141_thumb.jpg","galleries_id":287182,"server_id":32,"link":"photo_4128793.html","width":130,"caption":"","height":98});
															thumbnails[2775376] = clik.newPhoto({"id":2775376,"src":"P50576943_thumb.jpg","galleries_id":173891,"server_id":32,"link":"photo_2775376.html","width":130,"caption":"Oilseed fields, Allonby","height":173});
															thumbnails[2775393] = clik.newPhoto({"id":2775393,"src":"PC026083_thumb.jpg","galleries_id":173892,"server_id":32,"link":"photo_2775393.html","width":130,"caption":"","height":173});
															thumbnails[2776345] = clik.newPhoto({"id":2776345,"src":"Ibiza05-112_filtered_thumb.jpg","galleries_id":173890,"server_id":32,"link":"photo_2776345.html","width":130,"caption":"Ibiza Town","height":175});
															thumbnails[4128788] = clik.newPhoto({"id":4128788,"src":"PB309691_13_thumb.jpg","galleries_id":287182,"server_id":32,"link":"photo_4128788.html","width":130,"caption":"","height":173});
															thumbnails[2775362] = clik.newPhoto({"id":2775362,"src":"Ibiza05-1694_thumb.jpg","galleries_id":173890,"server_id":32,"link":"photo_2775362.html","width":130,"caption":"Ibiza","height":98});
															thumbnails[2775379] = clik.newPhoto({"id":2775379,"src":"P50677433_thumb.jpg","galleries_id":173891,"server_id":32,"link":"photo_2775379.html","width":130,"caption":"Newlands Valley","height":98});
															thumbnails[2775396] = clik.newPhoto({"id":2775396,"src":"PICT0001a_filtered_thumb.jpg","galleries_id":173892,"server_id":32,"link":"photo_2775396.html","width":130,"caption":"","height":98});
															thumbnails[4128772] = clik.newPhoto({"id":4128772,"src":"P52408441_thumb.jpg","galleries_id":287182,"server_id":32,"link":"photo_4128772.html","width":130,"caption":"","height":98});
															thumbnails[2775366] = clik.newPhoto({"id":2775366,"src":"Ibiza05-2183_thumb.jpg","galleries_id":173890,"server_id":32,"link":"photo_2775366.html","width":130,"caption":"","height":173});
															thumbnails[2775368] = clik.newPhoto({"id":2775368,"src":"P20327454_thumb.jpg","galleries_id":173892,"server_id":32,"link":"photo_2775368.html","width":130,"caption":"","height":98});
															thumbnails[2775380] = clik.newPhoto({"id":2775380,"src":"P7278729a3_thumb.jpg","galleries_id":173891,"server_id":32,"link":"photo_2775380.html","width":130,"caption":"Wildflower Meadow, Allerby","height":173});
															thumbnails[4128780] = clik.newPhoto({"id":4128780,"src":"P9100285_filtered2_thumb.jpg","galleries_id":287182,"server_id":32,"link":"photo_4128780.html","width":130,"caption":"","height":173});
															thumbnails[2775361] = clik.newPhoto({"id":2775361,"src":"Ibiza05-723_thumb.jpg","galleries_id":173890,"server_id":32,"link":"photo_2775361.html","width":130,"caption":"","height":98});
															thumbnails[2775374] = clik.newPhoto({"id":2775374,"src":"P40674063_thumb.jpg","galleries_id":173892,"server_id":32,"link":"photo_2775374.html","width":130,"caption":"","height":98});
															thumbnails[2775384] = clik.newPhoto({"id":2775384,"src":"P8319614_thumb.jpg","galleries_id":173891,"server_id":32,"link":"photo_2775384.html","width":130,"caption":"Buttermere in the rain","height":98});
															thumbnails[5076332] = clik.newPhoto({"id":5076332,"src":"PB309646_thumb.jpg","galleries_id":287182,"server_id":32,"link":"photo_5076332.html","width":130,"caption":"","height":98});
															thumbnails[2775386] = clik.newPhoto({"id":2775386,"src":"P9100285_filtered_thumb.jpg","galleries_id":173891,"server_id":32,"link":"photo_2775386.html","width":130,"caption":"Fleming Square, Maryport","height":173});
															thumbnails[2775398] = clik.newPhoto({"id":2775398,"src":"Snowdrop291_filtered3_thumb.jpg","galleries_id":173892,"server_id":32,"link":"photo_2775398.html","width":130,"caption":"","height":173});
															thumbnails[2776346] = clik.newPhoto({"id":2776346,"src":"Ibiza05-191_thumb.JPG","galleries_id":173890,"server_id":32,"link":"photo_2776346.html","width":130,"caption":"s'Argamassa, Ibiza","height":173});
															thumbnails[5076331] = clik.newPhoto({"id":5076331,"src":"PB309640_thumb.jpg","galleries_id":287182,"server_id":32,"link":"photo_5076331.html","width":130,"caption":"","height":173});
															thumbnails[2776413] = clik.newPhoto({"id":2776413,"src":"P7305104_thumb.jpg","galleries_id":173890,"server_id":32,"link":"photo_2776413.html","width":130,"caption":"Fuerteventura","height":98});
															thumbnails[2776415] = clik.newPhoto({"id":2776415,"src":"P8025335_thumb.jpg","galleries_id":173890,"server_id":32,"link":"photo_2776415.html","width":130,"caption":"Fuerteventura","height":173});
															thumbnails[2776417] = clik.newPhoto({"id":2776417,"src":"P7315143_thumb.jpg","galleries_id":173890,"server_id":32,"link":"photo_2776417.html","width":130,"caption":"Chipmunk, Fuerteventura","height":98});
															thumbnails[2776420] = clik.newPhoto({"id":2776420,"src":"P8015265_thumb.jpg","galleries_id":173890,"server_id":32,"link":"photo_2776420.html","width":130,"caption":"Fuerteventura","height":173});
															thumbnails[2776422] = clik.newPhoto({"id":2776422,"src":"P8045428_thumb.jpg","galleries_id":173890,"server_id":32,"link":"photo_2776422.html","width":130,"caption":"Museo del Sal, Fuerteventura","height":98});
															thumbnails[2776353] = clik.newPhoto({"id":2776353,"src":"P7024527001_thumb.jpg","galleries_id":173890,"server_id":32,"link":"photo_2776353.html","width":130,"caption":"Wilderswil, Switzerland","height":173});
															thumbnails[5076328] = clik.newPhoto({"id":5076328,"src":"P4260662_thumb.jpg","galleries_id":287182,"server_id":32,"link":"photo_5076328.html","width":130,"caption":"","height":85});
															thumbnails[2775388] = clik.newPhoto({"id":2775388,"src":"P7024502001_thumb.jpg","galleries_id":173890,"server_id":32,"link":"photo_2775388.html","width":130,"caption":"Interlaken, Switzerland","height":98});
															thumbnails[5076335] = clik.newPhoto({"id":5076335,"src":"PICT0007_thumb.jpg","galleries_id":287182,"server_id":32,"link":"photo_5076335.html","width":130,"caption":"","height":166});
															thumbnails[2775390] = clik.newPhoto({"id":2775390,"src":"P7024553001_thumb.jpg","galleries_id":173890,"server_id":32,"link":"photo_2775390.html","width":130,"caption":"Monch, from Wilderswil","height":174});
															thumbnails[4128759] = clik.newPhoto({"id":4128759,"src":"P42606871_thumb.jpg","galleries_id":287182,"server_id":32,"link":"photo_4128759.html","width":130,"caption":"","height":98});
															thumbnails[5076329] = clik.newPhoto({"id":5076329,"src":"P5311055_thumb.jpg","galleries_id":287182,"server_id":32,"link":"photo_5076329.html","width":130,"caption":"","height":173});
															thumbnails[2775389] = clik.newPhoto({"id":2775389,"src":"P7024503001_thumb.jpg","galleries_id":173890,"server_id":32,"link":"photo_2775389.html","width":130,"caption":"Interlaken, Switerland","height":98});
															thumbnails[4128777] = clik.newPhoto({"id":4128777,"src":"P61311791_thumb.jpg","galleries_id":287182,"server_id":32,"link":"photo_4128777.html","width":130,"caption":"","height":98});
															thumbnails[2775391] = clik.newPhoto({"id":2775391,"src":"P7044742001_thumb.jpg","galleries_id":173890,"server_id":32,"link":"photo_2775391.html","width":130,"caption":"","height":174});
															thumbnails[4128774] = clik.newPhoto({"id":4128774,"src":"P52408531_thumb.jpg","galleries_id":287182,"server_id":32,"link":"photo_4128774.html","width":130,"caption":"","height":173});
															thumbnails[4128776] = clik.newPhoto({"id":4128776,"src":"P60510611_thumb.jpg","galleries_id":287182,"server_id":32,"link":"photo_4128776.html","width":130,"caption":"","height":98});

/***************************************************************************
* Create the array of Gallery objects                                      *
***************************************************************************/
var galleries = new Object();
				  						galleries[287182] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Maryport","link":"gallery_287182.html","maxRecords":0.0,"photoIDs":[4128795.0,4128758.0,4128794.0,4128770.0,4128793.0,4128788.0,4128772.0,4128780.0,5076332.0,5076331.0,5076328.0,5076335.0,4128759.0,5076329.0,4128777.0,4128774.0,4128776.0],"skipIndex":0,"section_code":"gallery","featured_images":4128795.0,"id":287182,"singleSection":false});				  						galleries[271401] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Iceland","link":"gallery_271401.html","maxRecords":0.0,"photoIDs":[4727241.0,4735070.0,4735072.0,4735074.0,4735076.0,4735080.0,4735082.0,4735089.0,4735090.0,4735094.0,4735099.0,4735104.0,4735113.0,4735116.0,4735119.0],"skipIndex":0,"section_code":"gallery","featured_images":"4735119,4735116,4735113,4735104,4735099,4735094,4735090,4735089,4735082,4735080","id":271401,"singleSection":false});				  						galleries[173891] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Around Cumbria","link":"gallery_173891.html","maxRecords":0.0,"photoIDs":[5637441.0,5637452.0,5637445.0,5637449.0,5637454.0,2775350.0,2775351.0,2775353.0,2775370.0,2775354.0,2775376.0,2775379.0,2775380.0,2775384.0,2775386.0],"skipIndex":0,"section_code":"gallery","featured_images":2775376.0,"id":173891,"singleSection":false});				  						galleries[173890] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Destinations","link":"gallery_173890.html","maxRecords":0.0,"photoIDs":[7193358.0,2775358.0,2775356.0,2775360.0,2776244.0,2776345.0,2775362.0,2775366.0,2775361.0,2776346.0,2776413.0,2776415.0,2776417.0,2776420.0,2776422.0,2776353.0,2775388.0,2775390.0,2775389.0,2775391.0],"skipIndex":0,"section_code":"gallery","featured_images":2775361.0,"id":173890,"singleSection":false});				  						galleries[173980] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Destinations - UK","link":"gallery_173980.html","maxRecords":0.0,"photoIDs":[2776447.0,2777160.0,2777208.0,2777203.0,2777169.0],"skipIndex":0,"section_code":"gallery","featured_images":2776447.0,"id":173980,"singleSection":false});				  						galleries[173892] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Stockshots","link":"gallery_173892.html","maxRecords":0.0,"photoIDs":[2775369.0,2775367.0,2775397.0,2775372.0,2775385.0,2775393.0,2775396.0,2775368.0,2775374.0,2775398.0],"skipIndex":0,"section_code":"gallery","featured_images":2775393.0,"id":173892,"singleSection":false});/***************************************************************************
* Create the array of image sets                                           *
***************************************************************************/
var imageSets = {};
imageSets[1] = '4128795,2776447,4128758,4128794,4128770,2775360,4128793,4128788,2776345,4128772,4128780,5076332,5076331,2775398,5076328,5076335,5076329,4128759,2775390,4128774';
imageSets[2] = '4128795,2776447,2775393,2775376,2775361';
imageSets[3] = '7193358,5985304,5985299,5985295,5985293,5985289,5985285,5985282,5985278,5985276,5985273,5985270,5985266,5637454,5637452,5637449,5637445,5637441,5076335,5076332,5076331,5076329,5076328,4735119,4735116,4735113,4735104,4735099,4735094,4735090,4735089,4735082,4735080,4735076,4735074,4735072,4735070,4727241,4128795,4128794,4128793,4128788,4128782,4128780,4128778,4128777,4128776,4128774,4128772,4128770';
 /***************************************************************************
* Get a server path given an ID                                            *
***************************************************************************/
function getServerPath(server_id) {
	var val = -1;
		switch (server_id) {
		case 51:
		val = 'www12.clikpic.com/nmonckton/images';
		break;
	}
		switch (server_id) {
		case 0:
		val = 'http://www.clikpic.com/nmonckton/images';
		break;
	}
		switch (server_id) {
		case 1:
		val = 'http://www1.clikpic.com/nmonckton/images';
		break;
	}
		switch (server_id) {
		case 2:
		val = 'http://admin.clikpic.com/nmonckton/images';
		break;
	}
		switch (server_id) {
		case 24:
		val = 'http://tpc15/clikpic/nmonckton/images';
		break;
	}
		switch (server_id) {
		case 4:
		val = 'http://clikchurch.clikpic.com/nmonckton/images';
		break;
	}
		switch (server_id) {
		case 5:
		val = 'http://www2.clikpic.com/nmonckton/images';
		break;
	}
		switch (server_id) {
		case 22:
		val = 'http://tpc5/clikpic/nmonckton/images';
		break;
	}
		switch (server_id) {
		case 23:
		val = 'http://tpc10/clikpic/nmonckton/images';
		break;
	}
		switch (server_id) {
		case 25:
		val = 'http://tpc16/clikpic/nmonckton/images';
		break;
	}
		switch (server_id) {
		case 26:
		val = 'http://tpc20/clikpic/nmonckton/images';
		break;
	}
		switch (server_id) {
		case 40:
		val = 'http://www11.clikpic.com/nmonckton/images';
		break;
	}
		switch (server_id) {
		case 42:
		val = 'db2.clikpic.com/nmonckton/images';
		break;
	}
		switch (server_id) {
		case 15:
		val = 'http://www3.clikpic.com/nmonckton/images';
		break;
	}
		switch (server_id) {
		case 18:
		val = 'http://www4.clikpic.com/nmonckton/images';
		break;
	}
		switch (server_id) {
		case 19:
		val = 'http://www5.clikpic.com/nmonckton/images';
		break;
	}
		switch (server_id) {
		case 31:
		val = 'http://www7.clikpic.com/nmonckton/images';
		break;
	}
		switch (server_id) {
		case 32:
		val = 'http://www8.clikpic.com/nmonckton/images';
		break;
	}
		switch (server_id) {
		case 34:
		val = 'http://www9.clikpic.com/nmonckton/images';
		break;
	}
		switch (server_id) {
		case 35:
		val = 'http://admin3.clikpic.com/nmonckton/images';
		break;
	}
		switch (server_id) {
		case 37:
		val = 'http://admin4.clikpic.com/nmonckton/images';
		break;
	}
		switch (server_id) {
		case 38:
		val = 'http://admin5.clikpic.com/nmonckton/images';
		break;
	}
		switch (server_id) {
		case 39:
		val = 'http://www10.clikpic.com/nmonckton/images';
		break;
	}
		switch (server_id) {
		case 21:
		val = 'http://www6.clikpic.com/nmonckton/images';
		break;
	}
		switch (server_id) {
		case 50:
		val = '[cliktext value=article.servers_id type=servers_id]/nmonckton/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 && backgrounds[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 = 'npmimages: ' + 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.payment_groups_id !== '') {
		temp += '<p>Buy this print online:</p>';
				temp += '<form id="paymentOptions" style="margin:0px;border:0px;" name="paymentOptions">';
											temp += '<select class="paymentlink" name="payment_options_id" onchange="updateItemValues($(this.form).next(\'#paymentForm\')[0],this.form.payment_options_id.options[this.form.payment_options_id.options.selectedIndex].value);">';
		
		temp += getPaymentOptions(this.payment_groups_id);
		temp += '</select>';
		temp += '</form>';
				var item_option  = paymentGroups[this.payment_groups_id].options[0];
		if(paymentOptions[item_option]){
			var item_name  = paymentOptions[item_option].payment_option;
			var amount =  paymentOptions[item_option].price;
		}
			}
	else {
		
	}
	if (this.item_price !== '' || this.payment_groups_id !== '') {
			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;
	}
}

			

