window.thumbnails = {};
															thumbnails[9085800] = clik.newPhoto({"id":9085800,"src":"Untitled_Fukushima_Series_Phill_Hopkins_2012_thumb.jpg","galleries_id":353594,"server_id":18,"link":"photo_9085800.html","width":160,"caption":"Untitled (Fukushima Series) Phill Hopkins 2012","height":126});
															thumbnails[8791696] = clik.newPhoto({"id":8791696,"src":"Untitled_Phill_Hopkins_2011_a_CD62AA46-1EC9-DFB6-098059CDE88F756D_thumb.jpg","galleries_id":353594,"server_id":18,"link":"photo_8791696.html","width":160,"caption":"Untitled Phill Hopkins 2011","height":114});
															thumbnails[8791686] = clik.newPhoto({"id":8791686,"src":"Untitled_Phill_Hopkins_2011_e_thumb.JPG","galleries_id":353594,"server_id":18,"link":"photo_8791686.html","width":160,"caption":"Untitled Phill Hopkins 2011","height":230});
															thumbnails[8761979] = clik.newPhoto({"id":8761979,"src":"Untitled_Phill_Hopkins_2011_c_thumb.JPG","galleries_id":353594,"server_id":18,"link":"photo_8761979.html","width":160,"caption":"Untitled Phill Hopkins 2011","height":267});
															thumbnails[8730163] = clik.newPhoto({"id":8730163,"src":"Untitled_Phill_Hopkins_2011_k_thumb.jpg","galleries_id":353594,"server_id":18,"link":"photo_8730163.html","width":160,"caption":"The Future of the World Phill Hopkins 2011","height":98});
															thumbnails[8608376] = clik.newPhoto({"id":8608376,"src":"Untitled_Drawer_Phill_Hopkins_2011_thumb.JPG","galleries_id":353594,"server_id":18,"link":"photo_8608376.html","width":160,"caption":"Untitled Phill Hopkins 2011","height":214});
															thumbnails[8608407] = clik.newPhoto({"id":8608407,"src":"Untitled_Kit_Phill_Hopkins_2011_thumb.jpg","galleries_id":353594,"server_id":18,"link":"photo_8608407.html","width":160,"caption":"Untitled Phill Hopkins 2011","height":208});
															thumbnails[8589923] = clik.newPhoto({"id":8589923,"src":"Untitled_Phill_Hopkins_2011_z_25673096-1EC9-DFB6-095444B62FFC9700_thumb.JPG","galleries_id":353594,"server_id":18,"link":"photo_8589923.html","width":160,"caption":"Untitled Phill Hopkins 2011","height":254});
															thumbnails[8562203] = clik.newPhoto({"id":8562203,"src":"Untitled_Phill_Hopkins_2011_x_CB389AE9-1E4F-37DC-71CEA2D85F6CE0C4_thumb.jpg","galleries_id":353594,"server_id":18,"link":"photo_8562203.html","width":130,"caption":"Untitled Phill Hopkins 2011","height":185});
															thumbnails[9013415] = clik.newPhoto({"id":9013415,"src":"Untitled_Occupy_Phill_Hopkins_2012_sm_thumb.jpg","galleries_id":436924,"server_id":18,"link":"photo_9013415.html","width":160,"caption":"Untitled (Occupy) Phill Hopkins 2012","height":227});
															thumbnails[8459459] = clik.newPhoto({"id":8459459,"src":"Untitled_Rock_and_House_Phill_Hopkins_2011_thumb.JPG","galleries_id":353594,"server_id":18,"link":"photo_8459459.html","width":130,"caption":"Untitled (Rock and House) Phill Hopkins 2011","height":90});
															thumbnails[8608355] = clik.newPhoto({"id":8608355,"src":"Untitled_18_Drawings_Phill_Hopkins_2011_thumb.JPG","galleries_id":436926,"server_id":18,"link":"photo_8608355.html","width":160,"caption":"Untitled (18 Drawings) Phill Hopkins 2011","height":213});
															thumbnails[9013064] = clik.newPhoto({"id":9013064,"src":"UntitledPhill_Hopkins_2011_sm_thumb.jpg","galleries_id":436924,"server_id":18,"link":"photo_9013064.html","width":160,"caption":"Untitled Phill Hopkins 2011","height":225});
															thumbnails[8428756] = clik.newPhoto({"id":8428756,"src":"Place_1_Phill_Hopkins_2011_thumb.JPG","galleries_id":353594,"server_id":18,"link":"photo_8428756.html","width":130,"caption":"Place (One) Phill Hopkins 2011","height":97});
															thumbnails[8797146] = clik.newPhoto({"id":8797146,"src":"Houses_for_Trees_Phill_Hopkins_2011_Installation_view_Lange_Nacht_Der_Museen_Innsbruck_Austria_thumb.JPG","galleries_id":436926,"server_id":18,"link":"photo_8797146.html","width":160,"caption":"Houses for Trees Phill Hopkins 2011","height":106});
															thumbnails[9013056] = clik.newPhoto({"id":9013056,"src":"Untitled_Phill_Hopkins_2011_sm_D2D0D6C7-1EC9-DFB6-09C95E6DDDCCF332_thumb.jpg","galleries_id":436924,"server_id":18,"link":"photo_9013056.html","width":160,"caption":"Untitled Phill Hopkins 2011","height":224});
															thumbnails[8391658] = clik.newPhoto({"id":8391658,"src":"Place_Phill_Hopkins_2011_GB11_thumb.jpg","galleries_id":436926,"server_id":18,"link":"photo_8391658.html","width":130,"caption":"Place Phill Hopkins 2011","height":88});
															thumbnails[8428754] = clik.newPhoto({"id":8428754,"src":"Dwell_Phill_Hopkins_2011_thumb.JPG","galleries_id":353594,"server_id":18,"link":"photo_8428754.html","width":130,"caption":"Dwell Phill Hopkins 2011","height":81});
															thumbnails[9013052] = clik.newPhoto({"id":9013052,"src":"Untitled_murmur_Phill_Hopkins_2011_sm_thumb.JPG","galleries_id":436924,"server_id":18,"link":"photo_9013052.html","width":160,"caption":"Untitled (Murmur) Phill Hopkins 2011","height":233});
															thumbnails[8311743] = clik.newPhoto({"id":8311743,"src":"185354_10150347953621995_701046994_9912107_6294052_n_thumb.jpg","galleries_id":353594,"server_id":18,"link":"photo_8311743.html","width":130,"caption":"Untitled (Frame V) Phill Hopkins 2011","height":174});
															thumbnails[9013047] = clik.newPhoto({"id":9013047,"src":"UntitledPhillHopkins_2011_sm_thumb.JPG","galleries_id":436924,"server_id":18,"link":"photo_9013047.html","width":160,"caption":"Untitled Phill Hopkins 2011","height":229});
															thumbnails[9074658] = clik.newPhoto({"id":9074658,"src":"Studio_290112_sm_thumb.JPG","galleries_id":367143,"server_id":18,"link":"photo_9074658.html","width":160,"caption":"Studio 29:01:12","height":119});
															thumbnails[8141075] = clik.newPhoto({"id":8141075,"src":"Place_for_a_Kitchen_Phill_Hopkins_2011_61_thumb.JPG","galleries_id":436926,"server_id":18,"link":"photo_8141075.html","width":130,"caption":"Place for a Kitchen Phill Hopkins 2011","height":174});
															thumbnails[8168598] = clik.newPhoto({"id":8168598,"src":"Untitled_Frame_I_Phill_Hopkins_2011_thumb.jpg","galleries_id":353594,"server_id":18,"link":"photo_8168598.html","width":130,"caption":"Untitled (Frame I) Phill Hopkins 2011","height":285});
															thumbnails[9010600] = clik.newPhoto({"id":9010600,"src":"Untitled_a_Cathedral_inside_a_mosque_Phill_Hopkins_2011_sm_thumb.jpg","galleries_id":436924,"server_id":18,"link":"photo_9010600.html","width":160,"caption":"Untitled (A Cathedral inside a Mosque) Phill Hopkins 2011","height":232});
															thumbnails[9018041] = clik.newPhoto({"id":9018041,"src":"Studio_160112_sm_thumb.JPG","galleries_id":367143,"server_id":18,"link":"photo_9018041.html","width":160,"caption":"Studio 16:01:12","height":94});
															thumbnails[8168602] = clik.newPhoto({"id":8168602,"src":"Untitled_Frame_II_Phill_Hopkins_2011_thumb.jpg","galleries_id":353594,"server_id":18,"link":"photo_8168602.html","width":130,"caption":"Untitled (Frame II) Phill Hopkins 2011","height":280});
															thumbnails[8647641] = clik.newPhoto({"id":8647641,"src":"studio_20.10.11_thumb.jpg","galleries_id":367143,"server_id":18,"link":"photo_8647641.html","width":160,"caption":"Studio 20:10:11","height":214});
															thumbnails[9010598] = clik.newPhoto({"id":9010598,"src":"Untitled_Phill_Hopkins_2011_sm_thumb.JPG","galleries_id":436924,"server_id":18,"link":"photo_9010598.html","width":160,"caption":"Untitled Phill Hopkins 2011","height":221});
															thumbnails[8141084] = clik.newPhoto({"id":8141084,"src":"Place_for_a_Kitchen_Phill_Hopkins_2011_8_thumb.JPG","galleries_id":436926,"server_id":18,"link":"photo_8141084.html","width":130,"caption":"Ten Drawings - Place for a Kitchen Phill Hopkins 2011","height":174});
															thumbnails[8168604] = clik.newPhoto({"id":8168604,"src":"Untitled_Frame_III_Phill_Hopkins_2011_thumb.jpg","galleries_id":353594,"server_id":18,"link":"photo_8168604.html","width":130,"caption":"Untitled (Frame III) Phill Hopkins 2011","height":254});
															thumbnails[8567331] = clik.newPhoto({"id":8567331,"src":"Studio_031011_thumb.jpg","galleries_id":367143,"server_id":18,"link":"photo_8567331.html","width":130,"caption":"Studio 03:10:11","height":174});
															thumbnails[9010594] = clik.newPhoto({"id":9010594,"src":"Untitled_Phill_Hopkins_2011_sm-_thumb.JPG","galleries_id":436924,"server_id":18,"link":"photo_9010594.html","width":160,"caption":"Untitled Phill Hopkins 2011","height":227});
															thumbnails[8156392] = clik.newPhoto({"id":8156392,"src":"Place_for_a_Kitchen_Phill_Hopkins_2011_9_thumb.jpg","galleries_id":436926,"server_id":18,"link":"photo_8156392.html","width":130,"caption":"Place for a Kitchen Phill Hopkins 2011","height":174});
															thumbnails[8168777] = clik.newPhoto({"id":8168777,"src":"Untitled_Frame_IV_Phill_Hopkins_2011_thumb.jpg","galleries_id":353594,"server_id":18,"link":"photo_8168777.html","width":130,"caption":"Untitled (Frame IV) Phill Hopkins 2011","height":355});
															thumbnails[8567332] = clik.newPhoto({"id":8567332,"src":"Studio_03_1011_thumb.JPG","galleries_id":367143,"server_id":18,"link":"photo_8567332.html","width":130,"caption":"Studio 03:10:11","height":174});
															thumbnails[9010592] = clik.newPhoto({"id":9010592,"src":"Untitled_Levy_Phill_Hopkins_2011_sm_thumb.JPG","galleries_id":436924,"server_id":18,"link":"photo_9010592.html","width":160,"caption":"Untitled (Levy) Phill Hopkins 2011","height":224});
															thumbnails[7836278] = clik.newPhoto({"id":7836278,"src":"Place_at_HoMA_Phill_Hopkins_2011_1_thumb.JPG","galleries_id":436926,"server_id":18,"link":"photo_7836278.html","width":130,"caption":"Place Phill Hopkins 2011","height":184});
															thumbnails[8116261] = clik.newPhoto({"id":8116261,"src":"Untitled_Wings_Phill_Hopkins_2011_thumb.JPG","galleries_id":353594,"server_id":18,"link":"photo_8116261.html","width":130,"caption":"Untitled (Wings) Phill Hopkins 2011","height":159});
															thumbnails[8428760] = clik.newPhoto({"id":8428760,"src":"Studio_Phill_Hopkins_050911_thumb.JPG","galleries_id":367143,"server_id":18,"link":"photo_8428760.html","width":130,"caption":"Studio 05:09:11","height":174});
															thumbnails[9010590] = clik.newPhoto({"id":9010590,"src":"Untitled_Levee_Phill_Hopkins_2011_sm1_thumb.JPG","galleries_id":436924,"server_id":18,"link":"photo_9010590.html","width":160,"caption":"Untitled (Levee) Phill Hopkins 2011","height":225});
															thumbnails[7354380] = clik.newPhoto({"id":7354380,"src":"Untitled_Wing_2_Phill_Hopkins_2011_thumb.jpg","galleries_id":436924,"server_id":18,"link":"photo_7354380.html","width":130,"caption":"Untitled (Wing) Phill Hopkins 2011","height":183});
															thumbnails[7836279] = clik.newPhoto({"id":7836279,"src":"Place_HoMA_Phill_Hopkins_2011_3_thumb.JPG","galleries_id":436926,"server_id":18,"link":"photo_7836279.html","width":130,"caption":"Place Phill Hopkins 2011","height":132});
															thumbnails[8109766] = clik.newPhoto({"id":8109766,"src":"Studio_050711_thumb.jpg","galleries_id":367143,"server_id":18,"link":"photo_8109766.html","width":130,"caption":"Studio 05:07:11","height":97});
															thumbnails[8116269] = clik.newPhoto({"id":8116269,"src":"Untitled_Burnt_Phill_Hopkins_2011_thumb.JPG","galleries_id":353594,"server_id":18,"link":"photo_8116269.html","width":130,"caption":"Untitled Phill Hopkins 2011","height":151});
															thumbnails[9010588] = clik.newPhoto({"id":9010588,"src":"Untitled_Levee_Phill_Hopkins_2011_sm_thumb.JPG","galleries_id":436924,"server_id":18,"link":"photo_9010588.html","width":160,"caption":"Untitled (Levee) Phill Hopkins 2011","height":227});
															thumbnails[7354420] = clik.newPhoto({"id":7354420,"src":"Untitled_Never_is_always_becoming_Phill_Hopkins_2011_thumb.jpg","galleries_id":436924,"server_id":18,"link":"photo_7354420.html","width":130,"caption":"Untitled (Never is, always becoming) Phill Hopkins 2011","height":185});
															thumbnails[7836280] = clik.newPhoto({"id":7836280,"src":"Place_HoMA_Phill_Hopkins_2011_2_thumb.JPG","galleries_id":436926,"server_id":18,"link":"photo_7836280.html","width":130,"caption":"Place Phill Hopkins 2011","height":107});
															thumbnails[7851092] = clik.newPhoto({"id":7851092,"src":"Untitled_Phill_Hopkins_2011_61FB9625-1EC9-DFB6-098E6A7B085EA101_thumb.JPG","galleries_id":353594,"server_id":18,"link":"photo_7851092.html","width":130,"caption":"Untitled Phill Hopkins 2011","height":304});
															thumbnails[8109726] = clik.newPhoto({"id":8109726,"src":"Studio_040711_thumb.jpg","galleries_id":367143,"server_id":18,"link":"photo_8109726.html","width":130,"caption":"Studio 04:07:11","height":97});
															thumbnails[8608369] = clik.newPhoto({"id":8608369,"src":"Untitled_18_Drawings_Phill_Hopkins_2011_x_thumb.JPG","galleries_id":436924,"server_id":18,"link":"photo_8608369.html","width":160,"caption":"Untitled (18 Drawings) Phill Hopkins 2011","height":340});
															thumbnails[7851100] = clik.newPhoto({"id":7851100,"src":"Untitled_Never_is_always_becoming_Phill_Hopkins_2011_620E0F91-1EC9-DFB6-09B3948A661CDDD1_thumb.JPG","galleries_id":353594,"server_id":18,"link":"photo_7851100.html","width":130,"caption":"Untitled (Never is, always becoming) Phill Hopkins 2011","height":353});
															thumbnails[8338918] = clik.newPhoto({"id":8338918,"src":"Untitled_Fukushima_Series_Three_Phill_Hopkins_2011_thumb.jpg","galleries_id":436924,"server_id":18,"link":"photo_8338918.html","width":130,"caption":"Untitled (Fukushima Series Three) Phill Hopkins 2011","height":45});
															thumbnails[7555417] = clik.newPhoto({"id":7555417,"src":"Place._Phill_Hopkins_2011_thumb.JPG","galleries_id":436926,"server_id":18,"link":"photo_7555417.html","width":130,"caption":"Place Phill Hopkins 2011","height":178});
															thumbnails[7584412] = clik.newPhoto({"id":7584412,"src":"Untitled_Japan_Earthquake_I_Phill_Hopkins_2011_thumb.JPG","galleries_id":353594,"server_id":18,"link":"photo_7584412.html","width":130,"caption":"Untitled (Fukushima Series I) Phill Hopkins 2011","height":182});
															thumbnails[7675532] = clik.newPhoto({"id":7675532,"src":"Studio_180411_thumb.JPG","galleries_id":367143,"server_id":18,"link":"photo_7675532.html","width":130,"caption":"Studio 18:04:11","height":157});
															thumbnails[8338932] = clik.newPhoto({"id":8338932,"src":"Untitled_Fukushima_Series_Two_Phill_Hopkins_2011_thumb.JPG","galleries_id":436924,"server_id":18,"link":"photo_8338932.html","width":130,"caption":"Untitled (Fukushima Series Two) Phill Hopkins 2011","height":45});
															thumbnails[7584419] = clik.newPhoto({"id":7584419,"src":"Untitled_Japan_Earthquake_II_Phill_Hopkins_2011_thumb.JPG","galleries_id":353594,"server_id":18,"link":"photo_7584419.html","width":130,"caption":"Untitled (Fukushima Series II) Phill Hopkins 2011","height":211});
															thumbnails[7675530] = clik.newPhoto({"id":7675530,"src":"Studio_170411_thumb.jpg","galleries_id":367143,"server_id":18,"link":"photo_7675530.html","width":130,"caption":"Studio 17:04:11","height":174});
															thumbnails[7771867] = clik.newPhoto({"id":7771867,"src":"Place_detail_of_drawings_Phill_Hopkins_2011_thumb.jpg","galleries_id":436926,"server_id":18,"link":"photo_7771867.html","width":130,"caption":"Place Phill Hopkins 2011","height":86});
															thumbnails[8338912] = clik.newPhoto({"id":8338912,"src":"Untitled_Fukushima_Series_Four_Phill_Hopkins_2011_thumb.JPG","galleries_id":436924,"server_id":18,"link":"photo_8338912.html","width":130,"caption":"Untitled (Fukushima Series Four) Phill Hopkins 2011","height":46});
															thumbnails[7560810] = clik.newPhoto({"id":7560810,"src":"Place_Phill_Hopkins_2011_thumb.JPG","galleries_id":436926,"server_id":18,"link":"photo_7560810.html","width":130,"caption":"Place Phill Hopkins 2011","height":174});
															thumbnails[7569441] = clik.newPhoto({"id":7569441,"src":"Studio_240311__thumb.jpg","galleries_id":367143,"server_id":18,"link":"photo_7569441.html","width":130,"caption":"Studio 24:03:11","height":174});
															thumbnails[7584463] = clik.newPhoto({"id":7584463,"src":"Untitled_Japan_Earthquake_III_Phill_Hopkins_2011_thumb.JPG","galleries_id":353594,"server_id":18,"link":"photo_7584463.html","width":130,"caption":"Untitled (Fukushima Series III) Phill Hopkins 2011","height":176});
															thumbnails[8338907] = clik.newPhoto({"id":8338907,"src":"Place_Phill_Hopkins_2011_F29CE0F7-24E8-5EC4-4F6353A48A800F03_thumb.JPG","galleries_id":436924,"server_id":18,"link":"photo_8338907.html","width":130,"caption":"Place Phill Hopkins 2011","height":189});
															thumbnails[7504795] = clik.newPhoto({"id":7504795,"src":"IMG_1553_thumb.JPG","galleries_id":367143,"server_id":18,"link":"photo_7504795.html","width":130,"caption":"Studio 07:03:11","height":174});
															thumbnails[7573387] = clik.newPhoto({"id":7573387,"src":"Place_Phill_Hopkins_2011_3_thumb.JPG","galleries_id":436926,"server_id":18,"link":"photo_7573387.html","width":130,"caption":"Place Phill Hopkins 2011","height":159});
															thumbnails[7584467] = clik.newPhoto({"id":7584467,"src":"Untitled_Japan_Earthquake_IV_Phill_Hopkins_2011_thumb.JPG","galleries_id":353594,"server_id":18,"link":"photo_7584467.html","width":130,"caption":"Untitled (Fukushima Series IV) Phill Hopkins 2011","height":135});
															thumbnails[8304585] = clik.newPhoto({"id":8304585,"src":"Untitled_Hose_Phill_Hopkins_2011_thumb.JPG","galleries_id":436924,"server_id":18,"link":"photo_8304585.html","width":130,"caption":"Untitled (Hose) Phill Hopkins 2011","height":194});
															thumbnails[7584492] = clik.newPhoto({"id":7584492,"src":"Untitled_Japan_Earthquake_V_Phill_Hopkins_2011_thumb.JPG","galleries_id":353594,"server_id":18,"link":"photo_7584492.html","width":130,"caption":"Untitled (Fukushima Series V) Phill Hopkins 2011","height":139});
															thumbnails[8304563] = clik.newPhoto({"id":8304563,"src":"Untitled_Phill_Hopkins_2011_b_thumb.JPG","galleries_id":436924,"server_id":18,"link":"photo_8304563.html","width":130,"caption":"Untitled Phill Hopkins 2011","height":187});
															thumbnails[7584508] = clik.newPhoto({"id":7584508,"src":"Untitled_Japan_Earthquake_VI_Phill_Hopkins_2011_thumb.JPG","galleries_id":353594,"server_id":18,"link":"photo_7584508.html","width":130,"caption":"Untitled (Fukushima Series VI) Phill Hopkins 2011","height":190});
															thumbnails[8304527] = clik.newPhoto({"id":8304527,"src":"Untitled_Phill_Hopkins_2011_a_thumb.JPG","galleries_id":436924,"server_id":18,"link":"photo_8304527.html","width":130,"caption":"Untitled Phill Hopkins 2011","height":185});
															thumbnails[7337107] = clik.newPhoto({"id":7337107,"src":"Studio_25.01_thumb.jpg","galleries_id":367143,"server_id":18,"link":"photo_7337107.html","width":130,"caption":"Studio 25:01:11","height":174});
															thumbnails[8304509] = clik.newPhoto({"id":8304509,"src":"Untitled_Shelf_Phill_Hopkins_2011_thumb.JPG","galleries_id":436924,"server_id":18,"link":"photo_8304509.html","width":130,"caption":"Untitled (Shelf) Phill Hopkins 2011","height":182});
															thumbnails[7279495] = clik.newPhoto({"id":7279495,"src":"Studio_with_Untitled_Big_Society_Phill_Hopkins_2010_thumb.jpg","galleries_id":367143,"server_id":18,"link":"photo_7279495.html","width":130,"caption":"Studio 06:01:11","height":98});
															thumbnails[8183531] = clik.newPhoto({"id":8183531,"src":"Untitled_Phill_Hopkins_2011_z_thumb.jpg","galleries_id":436924,"server_id":18,"link":"photo_8183531.html","width":130,"caption":"Untitled Phill Hopkins 2011","height":78});
															thumbnails[7096109] = clik.newPhoto({"id":7096109,"src":"Studio_221110_Phill_Hopkins_thumb.jpg","galleries_id":367143,"server_id":18,"link":"photo_7096109.html","width":130,"caption":"Studio 22:11:10","height":98});
															thumbnails[7391044] = clik.newPhoto({"id":7391044,"src":"Untitled_Bag_Phill_Hopkins_2011_thumb.jpg","galleries_id":353594,"server_id":18,"link":"photo_7391044.html","width":130,"caption":"Untitled (Bag) Phill Hopkins 2011","height":173});
															thumbnails[8183518] = clik.newPhoto({"id":8183518,"src":"Untitled_Phill_Hopkins_2011_y_thumb.JPG","galleries_id":436924,"server_id":18,"link":"photo_8183518.html","width":130,"caption":"Untitled Phill Hopkins 2011","height":174});
															thumbnails[7147718] = clik.newPhoto({"id":7147718,"src":"Untitled_Mirror_x_Phill_Hopkins_2010_thumb.jpg","galleries_id":353594,"server_id":18,"link":"photo_7147718.html","width":130,"caption":"Untitled (Mirror) Phill Hopkins 2010","height":98});
															thumbnails[8183504] = clik.newPhoto({"id":8183504,"src":"Untitled_Phill_Hopkins_2011_x_thumb.jpg","galleries_id":436924,"server_id":18,"link":"photo_8183504.html","width":130,"caption":"Untitled Phill Hopkins 2011","height":253});
															thumbnails[6864091] = clik.newPhoto({"id":6864091,"src":"Studio_06_10_10_thumb.jpg","galleries_id":367143,"server_id":18,"link":"photo_6864091.html","width":130,"caption":"Studio 06.10.10","height":98});
															thumbnails[7147727] = clik.newPhoto({"id":7147727,"src":"Untitled_._Phill_Hopkins_2010_thumb.JPG","galleries_id":353594,"server_id":18,"link":"photo_7147727.html","width":130,"caption":"Untitled (Tea towel) Phill Hopkins 2010","height":85});
															thumbnails[7359303] = clik.newPhoto({"id":7359303,"src":"Untitled_National_Anxiety_Phill_Hopkins_2011_thumb.jpg","galleries_id":436924,"server_id":18,"link":"photo_7359303.html","width":130,"caption":"Untitled (National Anxiety) Phill Hopkins 2011","height":184});
															thumbnails[6809873] = clik.newPhoto({"id":6809873,"src":"Studion_270910_thumb.jpg","galleries_id":367143,"server_id":18,"link":"photo_6809873.html","width":130,"caption":"Studio 27:09:10","height":87});
															thumbnails[7279125] = clik.newPhoto({"id":7279125,"src":"Untitled_Big_Society_Phill_Hopkins_2010_thumb.jpg","galleries_id":353594,"server_id":18,"link":"photo_7279125.html","width":130,"caption":"Untitled (Big Society) Phill Hopkins 2011","height":226});
															thumbnails[7353292] = clik.newPhoto({"id":7353292,"src":"Untitled_Wing_Phill_Hopkins_2011_thumb.jpg","galleries_id":436924,"server_id":18,"link":"photo_7353292.html","width":130,"caption":"Untitled (Wing) Phill Hopkins 2011","height":184});
															thumbnails[7352980] = clik.newPhoto({"id":7352980,"src":"Untitled_for_Susanna_Phill_Hopkins_2010_thumb.jpg","galleries_id":353594,"server_id":18,"link":"photo_7352980.html","width":130,"caption":"Untitled (for Susanna) Phill Hopkins 2010","height":192});
															thumbnails[7361342] = clik.newPhoto({"id":7361342,"src":"Untitled_National_Anxiety_2_Phill_Hopkins_2011_thumb.jpg","galleries_id":436924,"server_id":18,"link":"photo_7361342.html","width":130,"caption":"Untitled (National Anxiety) 2 Phill Hopkins 2011","height":187});
															thumbnails[6513347] = clik.newPhoto({"id":6513347,"src":"Untitled_thumb.jpg","galleries_id":353594,"server_id":18,"link":"photo_6513347.html","width":130,"caption":"'Untitled (Cut out)' Phill Hopkins 2010","height":206});
															thumbnails[6690926] = clik.newPhoto({"id":6690926,"src":"Studio_09_thumb.jpg","galleries_id":367143,"server_id":18,"link":"photo_6690926.html","width":130,"caption":"Studio 07:09:10","height":173});
															thumbnails[7366645] = clik.newPhoto({"id":7366645,"src":"Untitled_Phill_Hopkins_2011_thumb.jpg","galleries_id":436924,"server_id":18,"link":"photo_7366645.html","width":130,"caption":"Untitled Phill Hopkins 2011","height":189});
															thumbnails[6513380] = clik.newPhoto({"id":6513380,"src":"_Guardian_Phill_Hopkins_2010_thumb.jpg","galleries_id":353594,"server_id":18,"link":"photo_6513380.html","width":130,"caption":"'Parent\/Guardian' Phill Hopkins 2010","height":98});
															thumbnails[6733424] = clik.newPhoto({"id":6733424,"src":"Studio_220810_thumb.jpg","galleries_id":367143,"server_id":18,"link":"photo_6733424.html","width":130,"caption":"Studio 22.08.10","height":98});
															thumbnails[7366657] = clik.newPhoto({"id":7366657,"src":"Untitled_2_Phill_Hopkins_2011_thumb.jpg","galleries_id":436924,"server_id":18,"link":"photo_7366657.html","width":130,"caption":"Untitled Phill Hopkins 2011","height":185});
															thumbnails[6513401] = clik.newPhoto({"id":6513401,"src":"Untitled_Made_from_thumb.jpg","galleries_id":353594,"server_id":18,"link":"photo_6513401.html","width":130,"caption":"'Untitled (made from)' Phill Hopkins 2010","height":178});
															thumbnails[6735587] = clik.newPhoto({"id":6735587,"src":"studio_1907_thumb.jpg","galleries_id":367143,"server_id":18,"link":"photo_6735587.html","width":130,"caption":"Studio 19.07.10","height":173});
															thumbnails[6513421] = clik.newPhoto({"id":6513421,"src":"I_fall_to_pieces_again_Phill_Hopkins_thumb.jpg","galleries_id":353594,"server_id":18,"link":"photo_6513421.html","width":130,"caption":"'I fall to pieces (again)' Phill Hopkins 2010","height":197});
															thumbnails[6823864] = clik.newPhoto({"id":6823864,"src":"Untitled_two_sons_and_mountain_Phill_Hopkins_20101_thumb.jpg","galleries_id":436924,"server_id":18,"link":"photo_6823864.html","width":130,"caption":"Untitled (Two sons and mountain) Phill Hopkins 2010","height":184});
															thumbnails[6766170] = clik.newPhoto({"id":6766170,"src":"Untitled_My_Church_Phill_Hopkins_2010_b_thumb.jpg","galleries_id":353594,"server_id":18,"link":"photo_6766170.html","width":130,"caption":"Untitled (My Church) Phill Hopkins 2010","height":167});
															thumbnails[7372632] = clik.newPhoto({"id":7372632,"src":"Untitled_Hes_got_a_good_job_2_Phill_Hopkins_2011_thumb.jpg","galleries_id":436924,"server_id":18,"link":"photo_7372632.html","width":130,"caption":"Untitled (He's got a good job) Phill Hopkins 2011","height":188});
															thumbnails[7354564] = clik.newPhoto({"id":7354564,"src":"Untitled_Plank_Phill_Hopkins_2011_thumb.jpg","galleries_id":436924,"server_id":18,"link":"photo_7354564.html","width":130,"caption":"Untitled (Plank) Phill Hopkins 2011","height":187});
															thumbnails[8308274] = clik.newPhoto({"id":8308274,"src":"Untitled_Japan_Earthquake_III_Phill_Hopkins_2011_D2DBD80C-24E8-5EC4-4F7EE4FB704727B5_thumb.jpg","galleries_id":381554,"server_id":18,"link":"photo_8308274.html","width":130,"caption":"Untitled (Fukushima Series III) Phill Hopkins 2011. Postcard","height":176});
															thumbnails[8572943] = clik.newPhoto({"id":8572943,"src":"2._Untitled_Phill_Hopkins_2011_thumb.jpg","galleries_id":381554,"server_id":18,"link":"photo_8572943.html","width":160,"caption":"Untitled Phill Hopkins 2011 Postcard","height":96});
															thumbnails[8857235] = clik.newPhoto({"id":8857235,"src":"Untitled_Phill_Hopkins_2011_c_8F090EFF-1E4F-37DC-7186A57EE427A5C5_thumb.JPG","galleries_id":381554,"server_id":18,"link":"photo_8857235.html","width":160,"caption":"Untitled Phill Hopkins 2011. Postcard","height":267});
															thumbnails[7049153] = clik.newPhoto({"id":7049153,"src":"Why_did_you_pen_thumb.jpg","galleries_id":381555,"server_id":18,"link":"photo_7049153.html","width":130,"caption":"Why did you doubt. Phill Hopkins 2010","height":77});
															thumbnails[7734754] = clik.newPhoto({"id":7734754,"src":"Place_postcard_thumb.jpg","galleries_id":381554,"server_id":18,"link":"photo_7734754.html","width":130,"caption":"Place Phill Hopkins 2010. Postcard","height":183});
															thumbnails[7049235] = clik.newPhoto({"id":7049235,"src":"we_are_all_mental_pen_thumb.jpg","galleries_id":381555,"server_id":18,"link":"photo_7049235.html","width":130,"caption":"We are all mental and all sane, all at the same time. Phill Hopkins 2009","height":73});
															thumbnails[7410935] = clik.newPhoto({"id":7410935,"src":"Untitled_Big_Society_Phill_Hopkins_2011_thumb.jpg","galleries_id":381554,"server_id":18,"link":"photo_7410935.html","width":130,"caption":"Untitled (Big Society) Phill Hopkins 2011. Postcard","height":200});
															thumbnails[7047427] = clik.newPhoto({"id":7047427,"src":"Parent-Guardian_2010_Phill_Hopkins_thumb.JPG","galleries_id":381554,"server_id":18,"link":"photo_7047427.html","width":130,"caption":"Parent\/Guardian Phill Hopkins 2010. Postcard","height":98});
															thumbnails[7047433] = clik.newPhoto({"id":7047433,"src":"Untitled_bricks_Phill_Hopkins_2010_4576714B-1E4F-37DC-7148455EEDD32C35_thumb.jpg","galleries_id":381554,"server_id":18,"link":"photo_7047433.html","width":130,"caption":"Untitled (Bricks) Phill Hopkins 2010. Postcard.","height":178});
															thumbnails[7047485] = clik.newPhoto({"id":7047485,"src":"Untitled_cut-out_2010_Phill_Hopkins_thumb.JPG","galleries_id":381554,"server_id":18,"link":"photo_7047485.html","width":130,"caption":"Untitled (Cut-out) Phill Hopkins 2010. Postcard","height":173});
															thumbnails[7047515] = clik.newPhoto({"id":7047515,"src":"Untitled_dropping_a_house_from_the_window_I_21._2010_Phill_Hopkins_thumb.JPG","galleries_id":381554,"server_id":18,"link":"photo_7047515.html","width":130,"caption":"Dropping a House from a Window 1. Phill Hopkins 2010. Postcard","height":98});
															thumbnails[7055816] = clik.newPhoto({"id":7055816,"src":"6_postcards_thumb.JPG","galleries_id":381554,"server_id":18,"link":"photo_7055816.html","width":130,"caption":"Pack of all 9 postcards","height":98});

/***************************************************************************
* Create the array of Gallery objects                                      *
***************************************************************************/
var galleries = new Object();
				  						galleries[381554] = clik.newGallery({"parentGallery":"","usePopups":true,"title":"postcards","link":"section453725_381554.html","maxRecords":0.0,"photoIDs":[8308274.0,8572943.0,8857235.0,7734754.0,7410935.0,7047427.0,7047433.0,7047485.0,7047515.0,7055816.0],"skipIndex":0,"section_code":"section453725","featured_images":7410935,"id":381554,"singleSection":false});				  						galleries[353594] = clik.newGallery({"parentGallery":"","usePopups":true,"title":"recent sculpture","link":"gallery_353594.html","maxRecords":0.0,"photoIDs":[9085800.0,8791696.0,8791686.0,8761979.0,8730163.0,8608376.0,8608407.0,8589923.0,8562203.0,8459459.0,8428756.0,8428754.0,8311743.0,8168598.0,8168602.0,8168604.0,8168777.0,8116261.0,8116269.0,7851092.0,7851100.0,7584412.0,7584419.0,7584463.0,7584467.0,7584492.0,7584508.0,7391044.0,7147718.0,7147727.0,7279125.0,7352980.0,6513347.0,6513380.0,6513401.0,6513421.0,6766170.0],"skipIndex":0,"section_code":"gallery","featured_images":"9085800,8791696,8791686,8761979,8730163,8608407,8608376,8589923,8562203,8459459,8428756,8428754,8311743,8168602,8168598,8116269,8116261,6513401,6513380","id":353594,"singleSection":false});				  						galleries[381555] = clik.newGallery({"parentGallery":"","usePopups":true,"title":"multiples","link":"section453725_381555.html","maxRecords":0.0,"photoIDs":[7049153.0,7049235.0],"skipIndex":0,"section_code":"section453725","featured_images":"7049235,7049153","id":381555,"singleSection":false});				  						galleries[436924] = clik.newGallery({"parentGallery":"","usePopups":true,"title":"recent drawing","link":"gallery_436924.html","maxRecords":0.0,"photoIDs":[9013415.0,9013064.0,9013056.0,9013052.0,9013047.0,9010600.0,9010598.0,9010594.0,9010592.0,9010590.0,7354380.0,9010588.0,7354420.0,8608369.0,8338918.0,8338932.0,8338912.0,8338907.0,8304585.0,8304563.0,8304527.0,8304509.0,8183531.0,8183518.0,8183504.0,7359303.0,7353292.0,7361342.0,7366645.0,7366657.0,6823864.0,7372632.0,7354564.0],"skipIndex":0,"section_code":"gallery","featured_images":"9013415,9013064,9013056,9013052,9013047,9010600,9010598,8608369,8338932,8338918,8338912,8304585,8304563,8304509,8183531,8183518,8183504,7353292","id":436924,"singleSection":false});				  						galleries[436926] = clik.newGallery({"parentGallery":"","usePopups":true,"title":"installation \/ exhibition","link":"gallery_436926.html","maxRecords":0.0,"photoIDs":[8608355.0,8797146.0,8391658.0,8141075.0,8141084.0,8156392.0,7836278.0,7836279.0,7836280.0,7555417.0,7771867.0,7560810.0,7573387.0],"skipIndex":0,"section_code":"gallery","featured_images":"8797146,8608355,8156392,8141084,8141075,7836280","id":436926,"singleSection":false});				  						galleries[367143] = clik.newGallery({"parentGallery":"","usePopups":true,"title":"studio","link":"gallery_367143.html","maxRecords":0.0,"photoIDs":[9074658.0,9018041.0,8647641.0,8567331.0,8567332.0,8428760.0,8109766.0,8109726.0,7675532.0,7675530.0,7569441.0,7504795.0,7337107.0,7279495.0,7096109.0,6864091.0,6809873.0,6690926.0,6733424.0,6735587.0],"skipIndex":0,"section_code":"gallery","featured_images":"9074658,9018041,8647641,8567332,8567331,8428760,6809873,6735587,6733424,6690926","id":367143,"singleSection":false});/***************************************************************************
* Create the array of image sets                                           *
***************************************************************************/
var imageSets = {};
imageSets[1] = '9085800,8791696,7047427,8791686,7047433,8761979,8730163,8608376,8608407,8589923,9013415,8562203,9013064,8608355,8459459,9013056,8797146,8428756,9013052,8428754,9074658,9013047,8311743,9018041,9010600,8168598,8141075,9010598,8647641,8168602,8567331,8141084,8567332,8156392,8428760,8116261,8116269,8608369,7836280,8338918,8338932,8338912,8304585,8304563,8304509,8183531,8183518,7096109,8183504,7353292,6690926,6513380,6735587,6513401';
imageSets[2] = '9085800,8791696,7047427,8791686,7047433,8761979,8730163,8608376,8608407,8589923,9013415,8562203,9013064,8608355,8459459,9013056,8797146,8428756,9013052,8428754,9074658,9013047,8311743,9018041,9010600,8168598,8141075,9010598,8647641,8168602,8567331,8141084,8567332,8156392,8428760,8116261,8116269,8608369,7836280,8338918,8338932,8338912,8304585,8304563,8304509,8183531,8183518,8183504,7353292,6809873,6690926,6733424,6513380,6735587,6513401';
imageSets[3] = '9085800,9074658,9018041,9013415,9013064,9013056,9013052,9013047,9010600,9010598,9010594,9010592,9010590,9010588,8857235,8797146,8791696,8791686,8761979,8730163,8647641,8608407,8608376,8608369,8608355,8589923,8572943,8567332,8567331,8562203,8459459,8428760,8428756,8428754,8391658,8338932,8338918,8338912,8338907,8311743,8308274,8304585,8304563,8304527,8304509,8183531,8183518,8183504,8168777,8168604';
 /***************************************************************************
* Get a server path given an ID                                            *
***************************************************************************/
function getServerPath(server_id) {
	var val = -1;
		switch (server_id) {
		case 51:
		val = 'http://www12.clikpic.com/Phill/images';
		break;
	}
		switch (server_id) {
		case 0:
		val = 'http://www.clikpic.com/Phill/images';
		break;
	}
		switch (server_id) {
		case 1:
		val = 'http://www1.clikpic.com/Phill/images';
		break;
	}
		switch (server_id) {
		case 2:
		val = 'http://admin.clikpic.com/Phill/images';
		break;
	}
		switch (server_id) {
		case 24:
		val = 'http://tpc15/clikpic/Phill/images';
		break;
	}
		switch (server_id) {
		case 4:
		val = 'http://clikchurch.clikpic.com/Phill/images';
		break;
	}
		switch (server_id) {
		case 5:
		val = 'http://www2.clikpic.com/Phill/images';
		break;
	}
		switch (server_id) {
		case 22:
		val = 'http://tpc5/clikpic/Phill/images';
		break;
	}
		switch (server_id) {
		case 23:
		val = 'http://tpc10/clikpic/Phill/images';
		break;
	}
		switch (server_id) {
		case 25:
		val = 'http://tpc16/clikpic/Phill/images';
		break;
	}
		switch (server_id) {
		case 26:
		val = 'http://tpc20/clikpic/Phill/images';
		break;
	}
		switch (server_id) {
		case 40:
		val = 'http://www11.clikpic.com/Phill/images';
		break;
	}
		switch (server_id) {
		case 42:
		val = 'db2.clikpic.com/Phill/images';
		break;
	}
		switch (server_id) {
		case 15:
		val = 'http://www3.clikpic.com/Phill/images';
		break;
	}
		switch (server_id) {
		case 18:
		val = 'http://www4.clikpic.com/Phill/images';
		break;
	}
		switch (server_id) {
		case 19:
		val = 'http://www5.clikpic.com/Phill/images';
		break;
	}
		switch (server_id) {
		case 31:
		val = 'http://www7.clikpic.com/Phill/images';
		break;
	}
		switch (server_id) {
		case 32:
		val = 'http://www8.clikpic.com/Phill/images';
		break;
	}
		switch (server_id) {
		case 34:
		val = 'http://www9.clikpic.com/Phill/images';
		break;
	}
		switch (server_id) {
		case 35:
		val = 'http://admin3.clikpic.com/Phill/images';
		break;
	}
		switch (server_id) {
		case 37:
		val = 'http://admin4.clikpic.com/Phill/images';
		break;
	}
		switch (server_id) {
		case 38:
		val = 'http://admin5.clikpic.com/Phill/images';
		break;
	}
		switch (server_id) {
		case 39:
		val = 'http://www10.clikpic.com/Phill/images';
		break;
	}
		switch (server_id) {
		case 53:
		val = 'http://images.clikpic.com/Phill/images';
		break;
	}
		switch (server_id) {
		case 52:
		val = 'http://tpc22/clikpic/Phill/images';
		break;
	}
		switch (server_id) {
		case 21:
		val = 'http://www6.clikpic.com/Phill/images';
		break;
	}
		switch (server_id) {
		case 50:
		val = '[cliktext value=article.servers_id type=servers_id]/Phill/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 = 'phill hopkins: ' + 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.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="updateCartValue($(this.form).next(\'#paymentForm\')[0],this.form.payment_options_id.options[this.form.payment_options_id.options.selectedIndex].value); if(divShowing(\'paymentConfirm\')){fadeOut(\'paymentConfirm\', 3)};">';
		
		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 += '<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="PHILL">';
			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;
	}
}

			

