window.thumbnails = new Object();
												thumbnails[2833863] = new thumbnail(2833863,'','','Me and My Camera_thumb.jpg',130, 98,32,'															#');
												thumbnails[2271679] = new thumbnail(2271679,'395025','Snowdrops','Snowdrops r s w_thumb.jpg',130, 98,32,'																			photo_2271679.html');
												thumbnails[2288371] = new thumbnail(2288371,'149002','CADER IDRIS','BOOK_PAGE_34_Website_thumb.jpg',126, 90,32,'																			photo_2288371.html');
												thumbnails[2317048] = new thumbnail(2317048,'149002','LLYN CYNWCH','WORKSHOP_018_Website_thumb.jpg',120, 90,32,'																			photo_2317048.html');
												thumbnails[2322964] = new thumbnail(2322964,'145721','LEEDS CASTLE','LEEDS CASTLE r s w_thumb.jpg',130, 98,32,'																			photo_2322964.html');
												thumbnails[2323081] = new thumbnail(2323081,'177066','','w1_thumb.jpg',130, 98,32,'																			photo_2323081.html');
												thumbnails[2323106] = new thumbnail(2323106,'149002','TORRENT WALK','BOOK_DULL_05_Website_thumb.jpg',121, 90,32,'																			photo_2323106.html');
												thumbnails[2333742] = new thumbnail(2333742,'145721','PORT MULGRAVE NORTH YORKSHIRE','PORT MULGRAVE SUNRISE_thumb.jpg',130, 98,32,'																			photo_2333742.html');
												thumbnails[2333802] = new thumbnail(2333802,'145728','GREYLAG GOOSE IN FLIGHT','GREYLAG GOOSE1_thumb.jpg',130, 104,32,'																			photo_2333802.html');
												thumbnails[2333812] = new thumbnail(2333812,'395025','BERRY TEMPTING','Berry_Tempting_e_s_r_Website_thumb.jpg',120, 90,32,'																			photo_2333812.html');
												thumbnails[2375434] = new thumbnail(2375434,'395025','Poppy Close-up','img007 r s_thumb.jpg',130, 85,32,'																			photo_2375434.html');
												thumbnails[2804578] = new thumbnail(2804578,'175382','KNOYDART','img142_Website_thumb.jpg',68, 90,32,'																			photo_2804578.html');
												thumbnails[2805168] = new thumbnail(2805168,'145728','Spider Monkey','SPIDER MONKEY e r s_thumb.jpg',130, 104,32,'																			photo_2805168.html');
												thumbnails[2805467] = new thumbnail(2805467,'145728','Robin','GARDEN ROBIN 191 e r s_thumb.jpg',130, 98,32,'																			photo_2805467.html');
												thumbnails[2805468] = new thumbnail(2805468,'145728','diving grebe','Diving Grebe c e r s_thumb.jpg',130, 86,32,'																			photo_2805468.html');
												thumbnails[2805475] = new thumbnail(2805475,'145728','kestrel','KESTREL e r s_thumb.jpg',130, 98,32,'																			photo_2805475.html');
												thumbnails[2805476] = new thumbnail(2805476,'145728','mother hen','MOTHER HEN e r s_thumb.jpg',130, 104,32,'																			photo_2805476.html');
												thumbnails[2822574] = new thumbnail(2822574,'177066','KENSAL GREEN CEMETERY','KENSAL GREEN 026 b&w e r c s_thumb.jpg',130, 98,32,'																			photo_2822574.html');
												thumbnails[2840509] = new thumbnail(2840509,'175382','CARN MOR DEARG ARETE','img117_Website_thumb.jpg',130, 87,32,'																			photo_2840509.html');
												thumbnails[2842873] = new thumbnail(2842873,'395025','COUNTERFEIT STONES','COUNTERFEIT STONES e r s_thumb.jpg',72, 90,32,'																			photo_2842873.html');
												thumbnails[2843061] = new thumbnail(2843061,'395025','THERMAL IMAGE','Science Museum Thermal Image 72ppi r_thumb.jpg',120, 90,32,'																			photo_2843061.html');
												thumbnails[2843246] = new thumbnail(2843246,'177066','WINDY DAY','WINDY DAY John Perriment r s_thumb.jpg',130, 87,32,'																			photo_2843246.html');
												thumbnails[2846218] = new thumbnail(2846218,'175382','VIEW FROM RAISE','img076_Website_thumb.jpg',130, 87,32,'																			photo_2846218.html');
												thumbnails[2846259] = new thumbnail(2846259,'175382','BEINN DUBHCHRAIG','img107_Website_thumb.jpg',130, 87,32,'																			photo_2846259.html');
												thumbnails[2875479] = new thumbnail(2875479,'175382','BEINN EIGHE','img127_Website_thumb.jpg',130, 87,32,'																			photo_2875479.html');
												thumbnails[4798790] = new thumbnail(4798790,'395025','Me and My Shadows','211_Double_Shadow_c_e_r_s__2_thumb.jpg',117, 90,32,'																			photo_4798790.html');
												thumbnails[4827322] = new thumbnail(4827322,'145728','peacock butterfly','NORFOLK_047_e_r_s_website_thumb.jpg',126, 90,32,'																			photo_4827322.html');
												thumbnails[4827324] = new thumbnail(4827324,'395025','the searchers','P6282389_e_s_website_thumb.jpg',72, 90,32,'																			photo_4827324.html');
												thumbnails[4827325] = new thumbnail(4827325,'395025','STUFFED FROGS','SCIENCE_MUSEUM_098_e_s_V2_Website_thumb.jpg',64, 90,32,'																			photo_4827325.html');
												thumbnails[4861576] = new thumbnail(4861576,'395025','Inverted Reflection','img207_e_r_s1_thumb.jpg',130, 87,32,'																			photo_4861576.html');
												thumbnails[4888317] = new thumbnail(4888317,'149002','LLYN GLAS SNOWDON','IMAGE_02_thumb.jpg',120, 90,32,'																			photo_4888317.html');
												thumbnails[5253519] = new thumbnail(5253519,'177066','HATFIELD FOREST','HATFIELD_FOREST_029_30_31_36_tonemapped_e_BW_r_s_web_thumb.jpg',120, 90,32,'																			photo_5253519.html');
												thumbnails[7248955] = new thumbnail(7248955,'141349','LINDSELL','RAKEFAIRS_TRACK_web_thumb.jpg',121, 90,32,'																			photo_7248955.html');
												thumbnails[7248968] = new thumbnail(7248968,'141349','DUNMOW','DUNMOW_web_thumb.jpg',68, 90,32,'																			photo_7248968.html');
												thumbnails[7249589] = new thumbnail(7249589,'393889','THE BENCH','HATFIELD_FOREST_tonemapped_e-Website_thumb.jpg',120, 90,32,'																			photo_7249589.html');
												thumbnails[7283587] = new thumbnail(7283587,'393889','WINTER HORNBEAM','HATFIELD_FOREST_002_e_website_thumb.jpg',120, 90,32,'																			photo_7283587.html');
												thumbnails[7283738] = new thumbnail(7283738,'393889','SPRING IN THE FOREST','091_e_c_version_3_Website_thumb.jpg',82, 90,32,'																			photo_7283738.html');
												thumbnails[7287507] = new thumbnail(7287507,'393889','SPRING MEADOWS','P5247390_e_r_s_Website_thumb.jpg',68, 90,32,'																			photo_7287507.html');
												thumbnails[7287564] = new thumbnail(7287564,'393889','HORSE CHESTNUT','HATFIELD_FOREST_060_e_r_s_Website_thumb.jpg',120, 90,32,'																			photo_7287564.html');
												thumbnails[7287578] = new thumbnail(7287578,'141349','STEBBING','09_EXTRA_COPY_r_s_Website_thumb.jpg',121, 90,32,'																			photo_7287578.html');
												thumbnails[7288660] = new thumbnail(7288660,'141349','POPPIES','BOOK_PAGE_37_Website_thumb.jpg',130, 86,32,'																			photo_7288660.html');
												thumbnails[7288693] = new thumbnail(7288693,'141349','GREAT EASTON','GREAT_EASTON_Website_thumb.jpg',108, 90,32,'																			photo_7288693.html');
												thumbnails[7288716] = new thumbnail(7288716,'141349','EPPING FOREST','EPPING_CARVED_TREE_Website_thumb.jpg',120, 90,32,'																			photo_7288716.html');
												thumbnails[7288767] = new thumbnail(7288767,'175382','HELVELLYN','BOOK_LIGHT_02_Website_thumb.jpg',130, 85,32,'																			photo_7288767.html');
												thumbnails[7288792] = new thumbnail(7288792,'141349','ST OSYTH CREEK','ST_OSYTHS_CREEK_Website_thumb.jpg',121, 90,32,'																			photo_7288792.html');
												thumbnails[7288821] = new thumbnail(7288821,'141349','ALRESFORD CREEK','ALRESFORD_CREEK_e_r_s_Website_thumb.jpg',121, 90,32,'																			photo_7288821.html');
												thumbnails[7288834] = new thumbnail(7288834,'141349','SECRET WOOD','DUTON_HILL_BLUEBELLS_Website_thumb.jpg',120, 90,32,'																			photo_7288834.html');
												thumbnails[7288872] = new thumbnail(7288872,'175382','BEN NEVIS','EASTER_ON_THE_BEN_Website_thumb.jpg',130, 87,32,'																			photo_7288872.html');
												thumbnails[7288887] = new thumbnail(7288887,'141349','THAXTED','THAXTED_GUILDHALL_Website_thumb.jpg',117, 90,32,'																			photo_7288887.html');
												thumbnails[7288905] = new thumbnail(7288905,'148783','BRANCASTER STAITHE','NORFOLK_002_e_Website_thumb.jpg',130, 63,32,'																			photo_7288905.html');
												thumbnails[7288925] = new thumbnail(7288925,'148783','WELLS NEXT THE SEA','BEACH_HUTS_WNTS_Website_thumb.jpg',105, 90,32,'																			photo_7288925.html');
												thumbnails[7289578] = new thumbnail(7289578,'148783','THORNHAM CREEK','THORNHAM_CREEK_Website_thumb.jpg',120, 90,32,'																			photo_7289578.html');
												thumbnails[7289591] = new thumbnail(7289591,'148783','BRANCASTER STAITHE','BRANCASTER_SUNSET_Workshop_thumb.jpg',120, 90,32,'																			photo_7289591.html');
												thumbnails[7289609] = new thumbnail(7289609,'148783','CLEY NEXT THE SEA','CLEY_NEXT_THE_SEA_Website_thumb.jpg',130, 67,32,'																			photo_7289609.html');
												thumbnails[7289612] = new thumbnail(7289612,'148783','BURNHAM OVERY STAITHE','BURNHAM_O_S_SUNRISE_Website_thumb.jpg',130, 83,32,'																			photo_7289612.html');
												thumbnails[7289651] = new thumbnail(7289651,'148783','BURNHAM OVERY STAITHE','BURNHAM_O_S_Website_thumb.jpg',119, 90,32,'																			photo_7289651.html');
												thumbnails[7289691] = new thumbnail(7289691,'148783','BURNHAM OVERY STAITHE','BURNHAM_O_S_SUNRISE_2_Website_thumb.jpg',130, 67,32,'																			photo_7289691.html');
												thumbnails[7289706] = new thumbnail(7289706,'149000','WASTWATER','WASTWATER_Website_thumb.jpg',130, 87,32,'																			photo_7289706.html');
												thumbnails[7289753] = new thumbnail(7289753,'149000','INNOMINATE TARN','INNOMINATE_TARN_Website_thumb.jpg',130, 84,32,'																			photo_7289753.html');
												thumbnails[7289767] = new thumbnail(7289767,'149000','CONISTON WATER','TOP_O_SELSIDE_Website_thumb.jpg',130, 84,32,'																			photo_7289767.html');
												thumbnails[7289784] = new thumbnail(7289784,'149000','LINGMOOR FELL','LINGMOOR_FELL_Website_thumb.jpg',130, 79,32,'																			photo_7289784.html');
												thumbnails[7290103] = new thumbnail(7290103,'149000','WINDERMERE','WATERHEAD_Website_thumb.jpg',130, 84,32,'																			photo_7290103.html');
												thumbnails[7290119] = new thumbnail(7290119,'149000','BUTTERMERE','SENTINELS_BUTTERMERE_Website_thumb.jpg',130, 85,32,'																			photo_7290119.html');
												thumbnails[7290123] = new thumbnail(7290123,'149000','INNOMINATE TARN','INNOMINATE__GABLE_Website_thumb.jpg',130, 84,32,'																			photo_7290123.html');
												thumbnails[7290134] = new thumbnail(7290134,'149000','HAYSTACKS','HAYSTACKS_Website_thumb.jpg',130, 84,32,'																			photo_7290134.html');
												thumbnails[7290142] = new thumbnail(7290142,'149000','ULLSWATER','ULLSWATER_DAWN_Website_thumb.jpg',130, 88,32,'																			photo_7290142.html');
												thumbnails[7290172] = new thumbnail(7290172,'149000','BUTTERMERE','BUTTERMERE_SUNSET_Website_thumb.jpg',130, 81,32,'																			photo_7290172.html');
												thumbnails[7290187] = new thumbnail(7290187,'175382','BLACKBECK TARN','BLACKBECK_CAMP_Website_thumb.jpg',130, 83,32,'																			photo_7290187.html');
												thumbnails[7290361] = new thumbnail(7290361,'175382','LOCH TORRIDON','LOCH_TORRIDON_Website_thumb.jpg',130, 83,32,'																			photo_7290361.html');
												thumbnails[7290394] = new thumbnail(7290394,'175382','BRECON BEACONS','BRECON_BEACONS_Website_thumb.jpg',60, 90,32,'																			photo_7290394.html');
												thumbnails[7290421] = new thumbnail(7290421,'175382','BEN LUI','BEN_LUI_Website_thumb.jpg',130, 84,32,'																			photo_7290421.html');
												thumbnails[7290796] = new thumbnail(7290796,'295794','BOSHAM','BOSHAM_FOG_Website_thumb.jpg',120, 90,32,'																			photo_7290796.html');
												thumbnails[7290832] = new thumbnail(7290832,'295794','BOSHAM','WEST_SUSSEX_164_Website_thumb.jpg',130, 71,32,'																			photo_7290832.html');
												thumbnails[7290843] = new thumbnail(7290843,'295794','BOSHAM','WEST_SUSSEX_089_Website_thumb.jpg',130, 66,32,'																			photo_7290843.html');
												thumbnails[7290876] = new thumbnail(7290876,'295794','BOSHAM','WEST_SUSSEX_104_Website_thumb.jpg',120, 90,32,'																			photo_7290876.html');
												thumbnails[7290924] = new thumbnail(7290924,'149001','NEAR ARISAIG','img139_e_Workshop_thumb.jpg',130, 87,32,'																			photo_7290924.html');
												thumbnails[7290939] = new thumbnail(7290939,'149001','LOCH COIRE MHIC FHEARCHAIR','img325_e_Website_thumb.jpg',130, 84,32,'																			photo_7290939.html');
												thumbnails[7290946] = new thumbnail(7290946,'149001','CALEDONIAN CANAL','WORKSHOP_045_Website_thumb.jpg',60, 90,32,'																			photo_7290946.html');
												thumbnails[7291053] = new thumbnail(7291053,'149001','LOCH KISHORN','LOCH_KISHORN_Website1_thumb.jpg',130, 62,32,'																			photo_7291053.html');
												thumbnails[7291058] = new thumbnail(7291058,'149001','LOCH TULLA','img330_e_Website1_thumb.jpg',130, 84,32,'																			photo_7291058.html');
												thumbnails[7291064] = new thumbnail(7291064,'149001','TORRIDONS','img302_e_Website1_thumb.jpg',130, 89,32,'																			photo_7291064.html');
												thumbnails[7291423] = new thumbnail(7291423,'149000','TEWET TARN','TEWET_TARN_Website_thumb.jpg',130, 62,32,'																			photo_7291423.html');
												thumbnails[7291451] = new thumbnail(7291451,'141349','DUNMOW','DUNMOW_RAPE_Website_thumb.jpg',121, 90,32,'																			photo_7291451.html');
												thumbnails[7291476] = new thumbnail(7291476,'149001','GLEN AFFRIC','img336_e_Website_thumb.jpg',88, 90,32,'																			photo_7291476.html');
												thumbnails[7291502] = new thumbnail(7291502,'145721','EMBLETON BAY NORTHUMBERLAND','img335_e_Website_thumb.jpg',120, 90,32,'																			photo_7291502.html');
												thumbnails[7291516] = new thumbnail(7291516,'149001','GLEN AFFRIC','img210_Website_thumb.jpg',99, 90,32,'																			photo_7291516.html');
												thumbnails[7292867] = new thumbnail(7292867,'145721','EMBLETON BAY','08_e_c_Website_thumb.jpg',130, 87,32,'																			photo_7292867.html');
												thumbnails[7292875] = new thumbnail(7292875,'145721','LEEDS CASTLE, KENT','img213_e_Website_thumb.jpg',120, 90,32,'																			photo_7292875.html');
												thumbnails[7293085] = new thumbnail(7293085,'145721','WALBERSWICK','img138_e_Website_thumb.jpg',130, 57,32,'																			photo_7293085.html');
												thumbnails[7293112] = new thumbnail(7293112,'145721','DOVE VALLEY, PEAK DISTRICT','img125_e_Website_thumb.jpg',123, 90,32,'																			photo_7293112.html');
												thumbnails[7293148] = new thumbnail(7293148,'278755','DUNMANUS QUAY COUNTY CORK','img124_e_Website_thumb.jpg',124, 90,32,'																			photo_7293148.html');
												thumbnails[7293271] = new thumbnail(7293271,'278755','ROCK ISLAND, COUNTY CORK','img120_USM_e_Website_thumb.jpg',123, 90,32,'																			photo_7293271.html');
												thumbnails[7293294] = new thumbnail(7293294,'278755','MOUNT GABRIEL COUNTY CORK','img115_e_Website_thumb.jpg',123, 90,32,'																			photo_7293294.html');
												thumbnails[7293505] = new thumbnail(7293505,'278755','INCH STRAND DINGLE','img119_FINAL_EDIT_Website_thumb.jpg',124, 90,32,'																			photo_7293505.html');
												thumbnails[7293627] = new thumbnail(7293627,'145721','SWALEDALE','img346_e_Website_thumb.jpg',130, 83,32,'																			photo_7293627.html');
												thumbnails[7293653] = new thumbnail(7293653,'145721','SPURN POINT','SPURN_POINT_01_e_layers_r_s_Website_thumb.jpg',120, 90,32,'																			photo_7293653.html');
												thumbnails[7293663] = new thumbnail(7293663,'145721','SKINNINGROVE','YORKSHIRE_COAST_221_e_Website_thumb.jpg',120, 90,32,'																			photo_7293663.html');
												thumbnails[7293667] = new thumbnail(7293667,'395025','KENSAL GREEN ','KENSAL_GREEN_066_e_r_s_Website_thumb.jpg',68, 90,32,'																			photo_7293667.html');
												thumbnails[7293671] = new thumbnail(7293671,'145721','SWALEDALE','BOOK_DEDI_PAGE_Website_thumb.jpg',81, 90,32,'																			photo_7293671.html');
												thumbnails[7293683] = new thumbnail(7293683,'141349','LINDSELL','RAKEFAIRS_069_edited_Website_thumb.jpg',68, 90,32,'																			photo_7293683.html');
												thumbnails[7293713] = new thumbnail(7293713,'141349','LINDSELL','RAKEFAIRS_037_e_Website_thumb.jpg',120, 90,32,'																			photo_7293713.html');
												thumbnails[7293721] = new thumbnail(7293721,'141349','SAFFRON WALDEN','WORKSHOP_008_Website_thumb.jpg',120, 90,32,'																			photo_7293721.html');
												thumbnails[7293724] = new thumbnail(7293724,'141349','EPPING FOREST','WORKSHOP_010_Website_thumb.jpg',120, 90,32,'																			photo_7293724.html');
												thumbnails[7293752] = new thumbnail(7293752,'393889','FOG AT THE FOREST','HATFIELD_FOREST_072_e_Website_thumb.jpg',120, 90,32,'																			photo_7293752.html');
												thumbnails[7293753] = new thumbnail(7293753,'393889','SOFT LIGHT','HATFIELD_FOREST_087_e_soft_Website_thumb.jpg',121, 90,32,'																			photo_7293753.html');
												thumbnails[7293755] = new thumbnail(7293755,'393889','AUTUMN GLORY','HATFIELD_FOREST_168_e_Website_thumb.jpg',120, 90,32,'																			photo_7293755.html');
												thumbnails[7293788] = new thumbnail(7293788,'393889','HINT OF MIST','HATFIELD_FOREST_192_e_Website_thumb.jpg',120, 90,32,'																			photo_7293788.html');
												thumbnails[7293792] = new thumbnail(7293792,'393889','LAST LIGHT','HATFIELD_FOREST_221_e_2_Website_thumb.jpg',120, 90,32,'																			photo_7293792.html');
												thumbnails[7293795] = new thumbnail(7293795,'393889','EERIE MIST','HATFIELD_FOREST_227_e1_c_Website_thumb.jpg',123, 90,32,'																			photo_7293795.html');
												thumbnails[7293798] = new thumbnail(7293798,'393889','SUNDOWN','HATFIELD_FOREST_239_e_Website_thumb.jpg',113, 90,32,'																			photo_7293798.html');
												thumbnails[7293843] = new thumbnail(7293843,'393889','SPLIT HORNBEAM','HATFIELD_FOREST_018_e_Website_thumb.jpg',121, 90,32,'																			photo_7293843.html');
												thumbnails[7293844] = new thumbnail(7293844,'393889','WINTER WONDERLAND','JANUARY_SNOW_082_e_straightened_Website_thumb.jpg',119, 90,32,'																			photo_7293844.html');
												thumbnails[7293848] = new thumbnail(7293848,'393889','CRISP AND EVEN','JANUARY_SNOW_085_e_Website_thumb.jpg',68, 90,32,'																			photo_7293848.html');
												thumbnails[7293851] = new thumbnail(7293851,'393889','FIELDS OF GOLD','img290_e_Website_thumb.jpg',67, 90,32,'																			photo_7293851.html');
												thumbnails[7293858] = new thumbnail(7293858,'393889','BUTTERCUP BLISS','img289_e_Website_thumb.jpg',118, 90,32,'																			photo_7293858.html');
												thumbnails[7296015] = new thumbnail(7296015,'149001','RIVER DEE','img334_e_Website_thumb.jpg',130, 79,32,'																			photo_7296015.html');
												thumbnails[7296029] = new thumbnail(7296029,'149001','ARISAIG','img300_e_Website_thumb.jpg',130, 79,32,'																			photo_7296029.html');
												thumbnails[7296083] = new thumbnail(7296083,'149001','RANNOCH RAINBOW','img350_e_Website_thumb.jpg',130, 62,32,'																			photo_7296083.html');
												thumbnails[7296141] = new thumbnail(7296141,'149001','RUM SUNSET','img345_e_Website_thumb.jpg',130, 56,32,'																			photo_7296141.html');
												thumbnails[7296272] = new thumbnail(7296272,'278755','BANTRY BAY','BOOK_PAGE_24_Website_thumb.jpg',130, 66,32,'																			photo_7296272.html');
												thumbnails[7296286] = new thumbnail(7296286,'278755','BALLYDONEGAN BAY','BOOK_PAGE_40A_Website_thumb.jpg',120, 90,32,'																			photo_7296286.html');
												thumbnails[7296315] = new thumbnail(7296315,'278755','GLENINCHIQUIN','BOOK_PAGE_39_Website_thumb.jpg',120, 90,32,'																			photo_7296315.html');
												thumbnails[7296334] = new thumbnail(7296334,'278755','GLENGARRIFF','IRELAND_2010_217_e_V3_Website_thumb.jpg',130, 71,32,'																			photo_7296334.html');
												thumbnails[7296363] = new thumbnail(7296363,'278755','GLENGARRIFF','IRELAND_2010_229_e_c_Website_thumb.jpg',130, 73,32,'																			photo_7296363.html');
												thumbnails[7296383] = new thumbnail(7296383,'278755','GLENGARRIFF','IRELAND_2010_240_e_Website_thumb.jpg',130, 73,32,'																			photo_7296383.html');
												thumbnails[7296393] = new thumbnail(7296393,'278755','ELLEN\'S ROCK','IRELAND_2010_318_e_Website_thumb.jpg',120, 90,32,'																			photo_7296393.html');
												thumbnails[7296440] = new thumbnail(7296440,'278755','ELLEN\'S ROCK','IRELAND_2010_343_40_39_tonemapped_e_V2_Website_thumb.jpg',130, 66,32,'																			photo_7296440.html');
												thumbnails[7296470] = new thumbnail(7296470,'278755','SEAL HARBOUR','IRELAND_2010_348_e_Website_thumb.jpg',120, 90,32,'																			photo_7296470.html');
												thumbnails[7296489] = new thumbnail(7296489,'278755','FARM NEAR ADRIGOLE','IRELAND_2010_356_e_Website_thumb.jpg',130, 65,32,'																			photo_7296489.html');
												thumbnails[7296501] = new thumbnail(7296501,'278755','FARM NEAR ADRIGOLE','IRELAND_2010_358_e_c_Website_thumb.jpg',124, 90,32,'																			photo_7296501.html');
												thumbnails[7296525] = new thumbnail(7296525,'278755','DURSEY ISLAND','IRELAND_2010_E_116_Website_thumb.jpg',120, 90,32,'																			photo_7296525.html');
												thumbnails[7296620] = new thumbnail(7296620,'149002','MOUNTAIN SUNRISE','img320_e_Website_thumb.jpg',130, 63,32,'																			photo_7296620.html');
												thumbnails[7296636] = new thumbnail(7296636,'149002','SNOWDON AT DAWN','img306_c_e_NR_Website_thumb.jpg',130, 61,32,'																			photo_7296636.html');
												thumbnails[7301832] = new thumbnail(7301832,'175382','BEINN ALLIGIN','img152_Website_thumb.jpg',60, 90,32,'																			photo_7301832.html');
												thumbnails[7301947] = new thumbnail(7301947,'175382','LLYN IDWAL','img154_Website_thumb.jpg',60, 90,32,'																			photo_7301947.html');
												thumbnails[7302124] = new thumbnail(7302124,'148783','THORNHAM CREEK','MAY_JUNE_07_083_Website_thumb.jpg',120, 90,32,'																			photo_7302124.html');
												thumbnails[7302139] = new thumbnail(7302139,'149002','TORRENT WALK','Torrent_Walk_e_s_Website_thumb.jpg',104, 90,32,'																			photo_7302139.html');
												thumbnails[7302187] = new thumbnail(7302187,'149002','TAL-Y-LLYN LAKE','Tal-y-llyn_Lake_2_e_s_Website_thumb.jpg',120, 90,32,'																			photo_7302187.html');
												thumbnails[7302200] = new thumbnail(7302200,'149002','CWM GLAS','img150_e_Website_thumb.jpg',130, 87,32,'																			photo_7302200.html');
												thumbnails[7302218] = new thumbnail(7302218,'148783','HOW HILL','img170_Website_thumb.jpg',119, 90,32,'																			photo_7302218.html');
												thumbnails[7302282] = new thumbnail(7302282,'149001','LOCH LOMOND','img103_e_Website_thumb.jpg',130, 87,32,'																			photo_7302282.html');
												thumbnails[7302295] = new thumbnail(7302295,'395025','DOOR 112A','DOOR_112A_thumb.jpg',79, 90,32,'																			photo_7302295.html');
												thumbnails[7302296] = new thumbnail(7302296,'149000','DEVOKE WATER','img095_Website_thumb.jpg',130, 87,32,'																			photo_7302296.html');
												thumbnails[7302318] = new thumbnail(7302318,'149000','DERWENT WATER','img080_e_Website_thumb.jpg',130, 87,32,'																			photo_7302318.html');
												thumbnails[7303773] = new thumbnail(7303773,'149000','BLEA TARN','BOOK_REFLECT_01_Website_thumb.jpg',130, 61,32,'																			photo_7303773.html');
												thumbnails[7303785] = new thumbnail(7303785,'149000','ULLSWATER','BOOK_REMAINS_02_Website_thumb.jpg',130, 87,32,'																			photo_7303785.html');
												thumbnails[7303857] = new thumbnail(7303857,'149000','NEWLANDS VALLLEY','BOOK_MIST_03_Website_thumb.jpg',130, 73,32,'																			photo_7303857.html');
												thumbnails[7303939] = new thumbnail(7303939,'149000','ESKDALE FELL','BOOK_CONTRAST_Website_thumb.jpg',130, 40,32,'																			photo_7303939.html');
												thumbnails[7303959] = new thumbnail(7303959,'149000','CONISTON WATER','BOOK_PAGE_15_Website_thumb.jpg',130, 85,32,'																			photo_7303959.html');
												thumbnails[7305497] = new thumbnail(7305497,'145721','EASTBRIDGE','WALBERSWICK_018_e_Website_thumb.jpg',120, 90,32,'																			photo_7305497.html');
												thumbnails[7305525] = new thumbnail(7305525,'141349','LINDSELL','BOOK_COVER_Website_thumb.jpg',105, 90,32,'																			photo_7305525.html');

/***************************************************************************
* Create the array of Gallery objects                                      *
***************************************************************************/
var galleries = new Object();
				  					galleries[175382] = new gallery(175382,'7288872','THE HILLS ARE ALIVE','gallery',[2804578,2840509,2846218,2846259,2875479,7288767,7288872,7290187,7290361,7290394,7290421,7301832,7301947],0, 0, '', '																																																																																																							gallery_175382.html',0,0);
				  					galleries[141349] = new gallery(141349,'7287578','ESSEX','gallery',[7248955,7248968,7287578,7288660,7288693,7288716,7288792,7288821,7288834,7288887,7291451,7293683,7293713,7293721,7293724,7305525],0, 0, '', '																																																																																																							gallery_141349.html',0,0);
				  					galleries[393889] = new gallery(393889,'7283587','HATFIELD FOREST','gallery',[7249589,7283587,7283738,7287507,7287564,7293752,7293753,7293755,7293788,7293792,7293795,7293798,7293843,7293844,7293848,7293851,7293858],0, 0, '', '																																																																																																							gallery_393889.html',0,0);
				  					galleries[148783] = new gallery(148783,'7289651','NORFOLK','gallery',[7288905,7288925,7289578,7289591,7289609,7289612,7289651,7289691,7302124,7302218],0, 0, '', '																																																																																																							gallery_148783.html',0,0);
				  					galleries[149000] = new gallery(149000,'7289767','THE LAKE DISTRICT','gallery',[7289706,7289753,7289767,7289784,7290103,7290119,7290123,7290134,7290142,7290172,7291423,7302296,7302318,7303773,7303785,7303857,7303939,7303959],0, 0, '', '																																																																																																							gallery_149000.html',0,0);
				  					galleries[295794] = new gallery(295794,'7290876','SUSSEX','gallery',[7290796,7290832,7290843,7290876],0, 0, '', '																																																																																																							gallery_295794.html',0,0);
				  					galleries[149001] = new gallery(149001,'7302282,7296141,7296083,7296029,7296015,7291516,7291476,7291064,7291058,7291053','SCOTLAND','gallery',[7290924,7290939,7290946,7291053,7291058,7291064,7291476,7291516,7296015,7296029,7296083,7296141,7302282],0, 0, '', '																																																																																																							gallery_149001.html',0,0);
				  					galleries[149002] = new gallery(149002,'2288371','WALES','gallery',[2288371,2317048,2323106,4888317,7296620,7296636,7302139,7302187,7302200],0, 0, '', '																																																																																																							gallery_149002.html',0,0);
				  					galleries[278755] = new gallery(278755,'7293271','IRELAND','gallery',[7293148,7293271,7293294,7293505,7296272,7296286,7296315,7296334,7296363,7296383,7296393,7296440,7296470,7296489,7296501,7296525],0, 0, '', '																																																																																																							gallery_278755.html',0,0);
				  					galleries[145721] = new gallery(145721,'2322964','OTHER PLACES','gallery',[2322964,2333742,7291502,7292867,7292875,7293085,7293112,7293627,7293653,7293663,7293671,7305497],0, 0, '', '																																																																																																							gallery_145721.html',0,0);
				  					galleries[145728] = new gallery(145728,'2805475','FUR & FEATHERS','gallery',[2333802,2805168,2805467,2805468,2805475,2805476,4827322],0, 0, '', '																																																																																																							gallery_145728.html',0,0);
				  					galleries[395025] = new gallery(395025,'2333812','MORE THAN JUST LANDSCAPES','gallery',[2271679,2333812,2375434,2842873,2843061,4798790,4827324,4827325,4861576,7293667,7302295],0, 0, '', '																																																																																																							gallery_395025.html',0,0);
				  					galleries[177066] = new gallery(177066,'5253519,2843246,2822574,2323081','BLACK & WHITE','gallery',[2323081,2822574,2843246,5253519],0, 0, '', '																																																																																																							gallery_177066.html',0,0);
/***************************************************************************
* Create the array of image sets                                           *
***************************************************************************/
var imageSets = new Object();
imageSets[1] = '7248955';
imageSets[2] = '7293271,7290876,7289767,7289651,7288872,7287578,7283587,2805475,2333812,2322964,2288371';
imageSets[3] = '7305525,7305497,7303959,7303939,7303857,7303785,7303773,7302318,7302296,7302295,7302282,7302218,7302200,7302187,7302139,7302124,7301947,7301832,7296636,7296620,7296525,7296501,7296489,7296470,7296440,7296393,7296383,7296363,7296334,7296315,7296286,7296272,7296141,7296083,7296029,7296015,7293858,7293851,7293848,7293844,7293843,7293798,7293795,7293792,7293788,7293755,7293753,7293752,7293724,7293721';
 /***************************************************************************
* Get a server path given an ID                                            *
***************************************************************************/
function getServerPath(server_id) {
	var val = -1;
		switch (server_id) {
		case 21:
		val = 'http://www6.clikpic.com/johnperriment/images';
		break;
	}
		switch (server_id) {
		case 1:
		val = 'http://www1.clikpic.com/johnperriment/images';
		break;
	}
		switch (server_id) {
		case 2:
		val = 'http://admin.clikpic.com/johnperriment/images';
		break;
	}
		switch (server_id) {
		case 24:
		val = 'http://tpc15/clikpic/johnperriment/images';
		break;
	}
		switch (server_id) {
		case 4:
		val = 'http://clikchurch.clikpic.com/johnperriment/images';
		break;
	}
		switch (server_id) {
		case 5:
		val = 'http://www2.clikpic.com/johnperriment/images';
		break;
	}
		switch (server_id) {
		case 22:
		val = 'http://tpc5/clikpic/johnperriment/images';
		break;
	}
		switch (server_id) {
		case 23:
		val = 'http://tpc10/clikpic/johnperriment/images';
		break;
	}
		switch (server_id) {
		case 25:
		val = 'http://tpc16/clikpic/johnperriment/images';
		break;
	}
		switch (server_id) {
		case 40:
		val = 'http://www11.clikpic.com/johnperriment/images';
		break;
	}
		switch (server_id) {
		case 42:
		val = 'db2.clikpic.com/johnperriment/images';
		break;
	}
		switch (server_id) {
		case 15:
		val = 'http://www3.clikpic.com/johnperriment/images';
		break;
	}
		switch (server_id) {
		case 18:
		val = 'http://www4.clikpic.com/johnperriment/images';
		break;
	}
		switch (server_id) {
		case 19:
		val = 'http://www5.clikpic.com/johnperriment/images';
		break;
	}
		switch (server_id) {
		case 31:
		val = 'http://www7.clikpic.com/johnperriment/images';
		break;
	}
		switch (server_id) {
		case 32:
		val = 'http://admin2.clikpic.com/johnperriment/images';
		break;
	}
		switch (server_id) {
		case 33:
		val = 'http://www8.clikpic.com/johnperriment/images';
		break;
	}
		switch (server_id) {
		case 34:
		val = 'http://www9.clikpic.com/johnperriment/images';
		break;
	}
		switch (server_id) {
		case 35:
		val = 'http://admin3.clikpic.com/johnperriment/images';
		break;
	}
		switch (server_id) {
		case 37:
		val = 'http://admin4.clikpic.com/johnperriment/images';
		break;
	}
		switch (server_id) {
		case 38:
		val = 'http://admin5.clikpic.com/johnperriment/images';
		break;
	}
		switch (server_id) {
		case 39:
		val = 'http://www10.clikpic.com/johnperriment/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:'',
                    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 (!basic) {
    if (op.updateHash && clik.getIDInUrl(location.href,'photo') != op.nextPhoto.id) {
		clik.changeHash('photos_id=' + op.nextPhoto.id, true);
    }
				
    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.$title.length > 0) {
  		op.$title.fadeGalleryDetails(photoCaption, op.speed);
    }
        if (op.updateDocumentTitle) {
						  document.title = 'John Perriment Photography: ' + photoCaption;
			    }
        if (op.$detail.length > 0) {
      temp = op.nextPhoto.fnGetImageDetails();
	    op.$detail.fadeGalleryDetails(temp, op.speed, function(){
	    var options = {};	    	      	      resizePhotoInfo(options);
        if (typeof(backgrounds) != 'undefined' && op.nextPhoto == backgrounds[op.nextPhoto.id]) {
  	      toggleAddToCartConfirm(backgrounds);
  	    } else if (typeof(photos) != 'undefined' && op.nextPhoto == photos[op.nextPhoto.id]) {
  	      toggleAddToCartConfirm(photos);
  	    }
	    });
    }
        if (!op.speed) {      clik.doColumnResize(false, op.$photo.add(op.$detail).add(op.$title));    }        
    return html;			}
	else {
				
		window.location = 'photo_' + nextPhoto.id + '.html';
	}
		
}

/***************************************************************************
* Toggle add to cart confirmation element and set up the click event for   *
* the 'Add to cart' button.                                                *
***************************************************************************/
function toggleAddToCartConfirm(array){
  if (typeof(array) !== 'object') {
    array = photos;
  }
	if($('#paymentConfirm').length > 0){
		$('#paymentConfirm').hide();
		$('#paymentAddButton')
		.unbind()
		.click(function(){
						form = document.getElementById('paymentForm');
			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').text('Item added to cart').show();}
				else{
					$('#paymentConfirm').text('Item added to cart').fadeIn();
					dspOrderDetails(form.site.value);
				}
			}
			else{
				$('#paymentConfirm').text('Item not added - check cookies are enabled in your browser.').fadeIn();
			}
		});
	}
}
/***************************************************************************
* Get payment info for image - add as 'method' to photo object             *
***************************************************************************/
photo.prototype.fnGetImageDetails = function(){
	var temp = '';
	if (this.description != '') {
		temp = temp +  '<p id="imageDescription">' + this.description + '</p>';
	}
		if (this.photo_ref != '') {
		temp = temp + '<p class="imageinfo" id="imageRef"><strong>Ref: </strong>' + this.photo_ref + '</p>';
	}
		if (this.takendate != '') {
				
		temp = temp + '<p class="imageinfo" id="imageDate"><strong>Date: </strong>' + this.takendate + '</p>';
	}
	
	if (this.location != '') {
				
		temp = temp + '<p class="imageinfo" id="imageLocation"><strong>Location: </strong>' +  this.location + '</p>';
	}
	
	if (this.photographer != '') {
				
		temp = temp + '<p class="imageinfo" id="imagePhotographer"><strong>Photographer: </strong>' + this.photographer + '</p>';
	}
					
	temp = temp + this.fnGetPaymentInfo();
				if (temp != '') {
		temp = temp + '<div class="spacer"></div>';
	}
	return temp;
};

/***************************************************************************
* Get payment info for image - add as 'method' to photo object             *
***************************************************************************/
photo.prototype.fnGetPaymentInfo = function(){
	var temp = '';
	if (this.item_price !== '') {
																		temp = temp + '<p>Buy now using PayPal:</p>';
				temp = temp + '<p class="imageinfo" id="imagePrice"><strong>' + this.purchase_instruction + '</strong> 				&pound;' + (this.item_price).toFixed(2) + '</p>';
		var item_name  = this.purchase_instruction;
		var amount = (this.item_price).toFixed(2);
		var item_option  = 0;
	}
	else if (this.payment_groups_id !== '') {
		temp = temp + '<p>Buy this print online:</p>';
				temp = temp + '<form id="paymentOptions" style="margin:0px;border:0px;" name="paymentOptions">';
		 									temp = temp + '<select class="paymentlink" name="payment_options_id" onchange="updateCartValue(document.forms.paymentForm,this.form.payment_options_id.options[this.form.payment_options_id.options.selectedIndex].value); if(divShowing(\'paymentConfirm\')){fadeOut(\'paymentConfirm\', 3)};">';
				
		temp = temp + getPaymentOptions(this.payment_groups_id);
		temp = temp + '</select>';
		temp = 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 = temp + '<form id="paymentForm" style="margin:0px;border:0px;" name="paymentForm">';
	temp = temp + '	<input type="hidden" name="item_option" value="' + item_option + '">';
	temp = temp + '	<input type="hidden" name="site" value="JOHNPERRIMENT">';
		temp = temp + '	<input type="hidden" name="item_number" value="'+ this.id +'">';
			temp = temp + '	<input type="hidden" name="quantity" value="1">';
								temp = temp + '	<input value="Add to cart" id="paymentAddButton" class="button" onmouseover="this.className=\'buttonHi\'\;" onmouseout="this.className=\'button\'\;" type="Button">';
			temp = 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 = temp + '</form>';
		temp = temp + '<div class="clearing">&nbsp;</div>';
	temp = temp + '<div id="confirmContainer">';
	temp = temp + '<div id="paymentConfirm">Item added to cart</div>';
	temp = temp + '</div>';
			temp = 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({            href: thumbnails[imageID].fnGalleryLink(gallery_id),            title: galleries[gallery_id].title          });
        }
							}
										}
}

/***************************************************************************
* 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 + ' | ';
				}
				temp = temp + '<a href="' + galleries[i].section_code + '_' + galleries[i].id + '.html">' + galleries[i].title + '</a>';
			}
		}
		document.all.galleryLinks.innerHTML = 'Other galleries: ' + temp;
	}
}

			

