function album(pToGet,psub) {

                         //year, year narrative
	aYear = new Array("2009,Below are some of our favourite photos from 2009"
	                 ,"2008,Below are some of our favourite photos from 2008"
		         );

                        //year,thumbnail width,venue,filename,caption 1 (tooltip), caption 2 (main caption)
	aImage 	= new Array ("2009,120,August,aug09Pacman01.jpg,City H3's 2nd Last Pacman Standing,The Ghosts are paraded<br />and what a surprise - its all the fast buggers!"
	                    ,"2009,120,August,aug09Pacman02.jpg,City H3's 2nd Last Pacman Standing,The rules seem a little complicated"
	                    ,"2009,120,August,aug09Pacman03.jpg,City H3's 2nd Last Pacman Standing,On out"
	                    ,"2009,120,August,aug09Pacman04.jpg,City H3's 2nd Last Pacman Standing,Watch out there's a ghost behind you!"
	                    ,"2009,120,August,aug09Pacman05.jpg,City H3's 2nd Last Pacman Standing,Pacladies united!"
	                    ,"2009,120,August,aug09Pacman06.jpg,City H3's 2nd Last Pacman Standing,Drink stop"
	                    ,"2009,68,August,aug09Pacman07.jpg,City H3's 2nd Last Pacman Standing,Catch us?<br />They don't have a ghost of a chance!"
	                    ,"2009,120,August,aug09Pacman08.jpg,City H3's 2nd Last Pacman Standing,A circle of ghosts haunt The Imperial at Leicester Square"
	                    ,"2009,68,August,aug09Pacman09.jpg,City H3's 2nd Last Pacman Standing,Baptised in beer"
	                    ,"2009,120,August,aug09Pacman10.jpg,City H3's 2nd Last Pacman Standing,The after party kicks off"
	                    ,"2009,68,August,aug09Stockwell01.jpg,Stockwell,Teapot is back!"
	                    ,"2009,93,August,aug09Stockwell08.jpg,Stockwell,and we are all pleased to see him"
	                    ,"2009,120,August,aug09Stockwell02.jpg,Stockwell,Love Wizard looking dynamic"
	                    ,"2009,120,August,aug09Stockwell03.jpg,Stockwell,Teapot takes the trail through a skateboard park"
	                    ,"2009,68,August,aug09Stockwell04.jpg,Stockwell,then into a dodgy council estate."
	                    ,"2009,68,August,aug09Stockwell05.jpg,Stockwell,Love Wizard sings for his down-down<br />after having his hat dunked in his pint!"
	                    ,"2009,68,August,aug09Stockwell06.jpg,Stockwell,Skylark receives a down-down for extreme hashing<br />(slaloming between posts on trail)"
	                    ,"2009,68,August,aug09Stockwell07.jpg,Stockwell,After months stuck in the desert&#44;<br />Teapot forgets what his wife looks like"
	                    ,"2009,120,August,aug09Stockwell09.jpg,Stockwell,Ryde is starting to wish that she hadn't ordered the budget taxi"
	                    ,"2009,99,August,aug09BrentSLASH03.jpg,Brentford SLASH,Swung Low is quiet at last.<br />He usually uses the on out to demonstrate that he can be noisier then a Teapot"
                            ,"2009,108,August,aug09BrentSLASH01.jpg,Brentford SLASH,Camera shy?<br />I'd say&#44 check out that Agincourt salute!"
	                    ,"2009,120,August,aug09BrentSLASH04.jpg,Brentford SLASH,One day Luberty will realise that baby faces are not a good idea when the baby looks as if he is about to be sick!"
	                    ,"2009,120,August,aug09BrentSLASH02.jpg,Brentford SLASH,2AM enjoying the beer stop"
	                    ,"2009,98,August,aug09BrentSLASH05.jpg,Brentford SLASH,Ha Ha Luberty has fallen asleep in the pub!<br />Maybe he needs a pillow."
	                    ,"2009,120,May,may09Ealing05.jpg,Ealing Broadway,Ealing Broadway"
	                    ,"2009,68,May,may09Ealing01.jpg,Ealing Broadway,Ealing greenery"
	                    ,"2009,120,May,may09Ealing06.jpg,Ealing Broadway,Circle up!"
	                    ,"2009,120,May,may09Ealing03.jpg,Ealing Broadway,Cheers!"
	                    ,"2009,120,May,may09Ealing04.jpg,Ealing Broadway,Hashers are getting even younger these days"
	                    ,"2009,120,April,apr09Chor11.jpg,Chorleywood,Chorleywood in the sun."
	                    ,"2009,68,April,apr09Chor01.jpg,Chorleywood,Photo shoot everyone"
			    ,"2009,120,April,apr09Chor02.jpg,Chorleywood,Little do they know its a dead end."
			    ,"2009,120,April,apr09Chor03.jpg,Chorleywood,'If only this map showed where the checks were'"
			    ,"2009,68,April,apr09Chor04.jpg,Chorleywood,The terrain becomes a bit more demanding."
		 	    ,"2009,120,April,apr09Chor05.jpg,Chorleywood,Over the river we go"
			    ,"2009,68,April,apr09Chor06.jpg,Chorleywood,and back again."
			    ,"2009,120,April,apr09Chor09.jpg,Chorleywood,'So many beers I just don't know which one to choose.'"
			    ,"2009,68,April,apr09Chor07.jpg,Chorleywood,Kneel Sir Mad Cow."
			    ,"2009,68,April,apr09Chor08.jpg,Chorleywood,Hair whitener for the hare"
			    ,"2009,120,April,apr09Chor10.jpg,Chorleywood,'A History of Passion'."
	                    ,"2009,68,March,mar09Barnes02.jpg,Barnes Bridge,On out"
			    ,"2009,68,March,mar09Barnes03.jpg,Barnes Bridge,The hash is a great place for building relationships&#44; as long as her husband does not find out!"
	                    ,"2009,120,March,mar09Barnes01.jpg,Barnes Bridge,A little bit of mud can't stop us"
	                    ,"2009,120,March,mar09Barnes04.jpg,Barnes Bridge,'What do we do at one of those funny circle things again?'"
	                    ,"2009,68,March,mar09Barnes05.jpg,Barnes Bridge,'Put him down&#44; you don't know where he's been!'"
	                    ,"2009,120,March,mar09And03.jpg,Andorra,The Soldeu Six<BR>Left to right: Marxist&#44 Beer Banger&#44; Anna (Roger the Cabin Boy)&#44; Pork Pie&#44; Boy Wonder - and Skylark behind the camera."
	                    ,"2009,100,March,mar09And07.jpg,Andorra,Anna with Blunder and Beer Banger"
	                    ,"2009,89,March,mar09And01.jpg,Andorra,sun worshiping"
	                    ,"2009,68,March,mar09And02.jpg,Andorra,mean pimp Pork Pie shows his bitches whos boss"
	                    ,"2009,120,March,mar09And04.jpg,Andorra,Skylark with bells on"
	                    ,"2009,98,March,mar09And05.jpg,Andorra,Boy Blunder"
	                    ,"2009,92,March,mar09And06.jpg,Andorra,Anna cheerful after lots of chocolate"
	                    ,"2009,128,March,mar09And08.jpg,Andorra,Skylark and Anna after emptying all those glasses"
	                    ,"2009,120,March,mar09And09.jpg,Andorra,Marxist on the piste"
	                    ,"2009,64,March,mar09And10.jpg,Andorra,Later that evening Beer Banger proves that he can drive better after a skin full of lager and gin and tonic than Pork Pie can when sober!"
	                    ,"2009,69,March,mar09wray01.jpg,Wraysbury,Just popped to the shops"
	                    ,"2009,68,March,mar09wray02.jpg,Wraysbury,Blooming marvelous"
	                    ,"2009,68,March,mar09wray03.jpg,Wraysbury,Wraysbury riverside"
	                    ,"2009,120,March,mar09wray04.jpg,Wraysbury,Watch your step"
	                    ,"2009,67,March,mar09wray05.jpg,Wraysbury,oops ... splash"
	                    ,"2009,120,March,mar09wray06.jpg,Wraysbury,go on ... push her in"
	                    ,"2009,120,March,mar09wray07.jpg,Wraysbury,I fall ... you fall"
	                    ,"2009,68,March,mar09wray08.jpg,Wraysbury,the fields are alive with the sound of ... on on!"
	                    ,"2009,68,March,mar09wray09.jpg,Wraysbury,climbing through a fence Hollywood style"
	                    ,"2009,120,March,mar09wray10.jpg,Wraysbury,stopping to pet the locals"
	                    ,"2009,120,March,mar09wray11.jpg,Wraysbury,On Inn"
	                    ,"2009,44,March,mar09wray12.jpg,Wraysbury,no your not going to try to drink two pints at once"
	                    ,"2009,44,March,mar09cat01.jpg,Catford,Boggers looking dynamic in Catford"
	                    ,"2009,54,March,mar09cat02.jpg,Catford,Catford"
	                    ,"2009,68,March,mar09cat03.jpg,Catford,Catford"
	                    ,"2009,58,March,mar09cat04.jpg,Catford,Holy Catford"
	                    ,"2009,41,March,mar09cat05.jpg,Catford,This hash is not for beer bellies!"
	                    ,"2009,59,March,mar09cat06.jpg,Catford,Leafy Catford"
	                    ,"2009,79,March,mar09cat07.jpg,Catford,Drink stop"
	                    ,"2009,48,March,mar09cat08.jpg,Catford,spot the ape"
	                    ,"2009,48,March,mar09cat09.jpg,Catford,and into the circle you shall go ..."
	                    ,"2009,57,February,feb09Hanwell01.jpg,Hanwell,Hanwell"
	                    ,"2009,120,February,feb09Hanwell02.jpg,Hanwell,Nobody open the gates!"
	                    ,"2009,68,February,feb09Hanwell03.jpg,Hanwell,Hanwell hash under the famous viaduct"
	                    ,"2009,68,February,feb09Hanwell04.jpg,Hanwell,Naming ceremony"
	                    ,"2009,120,February,feb09Hanwell05.jpg,Hanwell,Cheers!"
	                    ,"2009,120,February,feb09Hanwell06.jpg,Hanwell,Barman's view of the hash"	                    
	                    ,"2009,120,January,jan09Northolt01.jpg,Northolt,Warming up waiting for the hares" 
                            ,"2009,68,January,jan09Northolt02.jpg,Northolt,The Hill"
                            ,"2009,120,January,jan09Northolt03.jpg,Northolt,The Hill"
                            ,"2009,120,January,jan09Northolt04.jpg,Northolt,The Park"
                            ,"2009,120,January,jan09Northolt05.jpg,Northolt,The Canal"
                            ,"2009,120,January,jan09Northolt06.jpg,Northolt,The Beer stop"
                            ,"2009,120,January,jan09Northolt07.jpg,Northolt,We will do anything to get at beer!"
                            ,"2009,68,January,jan09Northolt08.jpg,Northolt,Showing some leg in the circle"
                            ,"2009,120,January,jan09Clapton03.jpg,Clapton,Dithering"
                            ,"2009,68,January,jan09Clapton02.jpg,Clapton,The Circle - the classic method of consuming alcohol."
                            ,"2009,68,January,jan09Clapton01.jpg,Clapton,The Circle - the Teapot method!" 	
                            ,"2009,120,January,jan09Ricky01.jpg,Rickmansworth,What a surprise - we end up running alongside a canal ..." 
                            ,"2009,120,January,jan09Ricky02.jpg,Rickmansworth,and then jumping one!"
                            ,"2009,120,January,jan09Ricky03.jpg,Rickmansworth,Its time for a wee dram"
                            ,"2009,68,January,jan09Ricky04.jpg,Rickmansworth,Down downs as it pours down"
                            ,"2009,120,January,jan09Ricky05.jpg,Rickmansworth,Teapot with his mouth open."
                            ,"2009,120,January,jan09Ricky06.jpg,Rickmansworth,Ode to the haggis"
                            ,"2009,68,January,jan09Ricky07.jpg,Rickmansworth,Yum!"
                            ,"2008,120,October,oct08Solest01.jpg,Sole Street,First weekend winter run of 2008<BR>from The Railway at Sole Street"
                            ,"2008,120,October,oct08Solest02.jpg,Sole Street,First weekend winter run of 2008<BR>from The Railway at Sole Street"
                            ,"2008,67,October,oct08Solest03.jpg,Sole Street,First weekend winter run of 2008<BR>from The Railway at Sole Street"
                            ,"2008,51,October,oct08Solest04.jpg,Sole Street,First weekend winter run of 2008<BR>from The Railway at Sole Street"
                            ,"2008,94,October,oct08Solest05.jpg,Sole Street,First weekend winter run of 2008<BR>from The Railway at Sole Street"
                            ,"2008,96,October,oct08Solest06.jpg,Sole Street,First weekend winter run of 2008<BR>from The Railway at Sole Street"
                            ,"2008,89,October,oct08Solest07.jpg,Sole Street,First weekend winter run of 2008<BR>from The Railway at Sole Street"
                            ,"2008,108,October,oct08Barnes01.jpg,Barnes Bridge,London Hash Annual General Piss Up<BR>in The Bulls Head at Barnes Bridge"
                            ,"2008,80,October,oct08Barnes02.jpg,Barnes Bridge,London Hash Annual General Piss Up<BR>in The Bulls Head at Barnes Bridge"
                            ,"2008,48,October,oct08Barnes03.jpg,Barnes Bridge,London Hash Annual General Piss Up<BR>in The Bulls Head at Barnes Bridge"
                            ,"2008,50,October,oct08Barnes04.jpg,Barnes Bridge,London Hash Annual General Piss Up<BR>in The Bulls Head at Barnes Bridge"
                            ,"2008,91,October,oct08Barnes05.jpg,Barnes Bridge,London Hash Annual General Piss Up<BR>in The Bulls Head at Barnes Bridge"
                            ,"2008,80,October,oct08Barnes06.jpg,Barnes Bridge,London Hash Annual General Piss Up<BR>in The Bulls Head at Barnes Bridge"
                            ,"2008,120,October,oct08Barnes07.jpg,Barnes Bridge,London Hash Annual General Piss Up<BR>in The Bulls Head at Barnes Bridge"
                            ,"2008,73,October,oct08Barnes08.jpg,Barnes Bridge,London Hash Annual General Piss Up<BR>Hash Grub"
                            ,"2008,68,October,oct08Barnes09.jpg,Barnes Bridge,London Hash Annual General Piss Up<BR>Feeding frenzy"
                            ,"2008,78,October,oct08Barnes10.jpg,Barnes Bridge,London Hash Annual General Piss Up<BR>in The Bulls Head at Barnes Bridge"
                            ,"2008,120,October,oct08Barnes11.jpg,Barnes Bridge,London Hash Annual General Piss Up<BR>Goodbye to the old committee"                                                        
                            ,"2008,133,October,oct08Barnes12.jpg,Barnes Bridge,London Hash Annual General Piss Up<BR>Hello to the new committee"  
                            ,"2008,77,October,oct08Kew01.jpg,Kew Bridge,Kew Bridge"  
                            ,"2008,120,October,oct08Kew02.jpg,Kew Bridge,Kew Bridge" 
                            ,"2008,121,October,oct08Kew03.jpg,Kew Bridge,Kew Bridge" 
                            ,"2008,120,October,oct08Kew04.jpg,Kew Bridge,Kew Bridge Drink Stop" 
                            ,"2008,120,October,oct08Kew05.jpg,Kew Bridge,Kew Bridge Drink Stop" 
                            ,"2008,88,October,oct08Kew06.jpg,Kew Bridge,Kew Bridge Drink Stop" 
                            ,"2008,55,October,oct08Kew07.jpg,Kew  Bridge,Kew Bridge Drink Stop" 
                            ,"2008,120,October,oct08Kew08.jpg,Kew Bridge,Kew Bridge Drink Stop" 
                            ,"2008,120,October,oct08Kew09.jpg,Kew Bridge,Kew Bridge Circle" 
                            ,"2008,68,October,oct08Kew10.jpg,Kew Bridge, Kew Bridge Circle" 
                            ,"2008,65,October,oct08Kew11.jpg,Kew Bridge,Kew Bridge Circle"                             
	                    ,"2008,53,September,sep08Richmond02.jpg,Richmond,Last Monday run of 2008<BR>from The Marlborough in Richmond"
                            ,"2008,54,September,sep08Richmond03.jpg,Richmond,Last Monday run of 2008<BR>from The Marlborough in Richmond"
                            ,"2008,60,September,sep08Richmond04.jpg,Richmond,Last Monday run of 2008<BR>from The Marlborough in Richmond"
                            ,"2008,97,September,sep08Richmond01.jpg,Richmond,Last Monday run of 2008<BR>from The Marlborough in Richmond"
                            ,"2008,97,September,sep08Richmond05.jpg,Richmond,Last Monday run of 2008<BR>from The Marlborough in Richmond"
                            ,"2008,75,September,sep08Richmond06.jpg,Richmond,Last Monday run of 2008<BR>from The Marlborough in Richmond"
                            ,"2008,82,September,sep08Richmond07.jpg,Richmond,Last Monday run of 2008<BR>from The Marlborough in Richmond"
                            ,"2008,85,September,sep08Richmond08.jpg,Richmond,Last Monday run of 2008<BR>from The Marlborough in Richmond"
			);

	function getReq() {

              search_request = new String;
	      l_req = new String;
	      l_req = "-1";

              search_request = this.location.search;

              if(search_request.length > 1) {
	        l_req = search_request.substring(1,search_request.length);
	      }

	      return parseInt(l_req);

	}
	
	function getYearDetails(pindex,psub) {
	
          re = /,/g

	  if (pindex > getYearCount()) {
	    pindex = getYearCount();
	  }
	
	  yearSplit = aYear[pindex].split(re)
	
	  return yearSplit[psub];
	}

	function getImageDetails(pindex,psub) {
	
          re = /,/g
	
	  if (pindex > getImageCount()) {
	    pindex = getImageCount();
	  }
	
	  imageSplit = aImage[pindex].split(re)
	
	  return imageSplit[psub];
	}


	function getYearCount() {
	  l_length = aYear.length - 1;

	  return l_length;
	}

	function getImageCount() {
	  l_length = aImage.length - 1;

	  return l_length;
	}

	function getYear(l_index) {

              return getYearDetails(l_index,0);

	}
	
	function getYearDesc(l_index) {
	
	      return getYearDetails(l_index,1);
	
	}
	
	function getImageYear(l_index) {
	
	      return getImageDetails(l_index,0);
	
	}
	
	function getImageThumbWidth(l_index) {
	
	      return parseInt(getImageDetails(l_index,1));
	
	}
	
	function getLocation(l_index) {
	
	      return getImageDetails(l_index,2);
	
	}	
	
	function getFilename(l_index) {
	
	      return getImageDetails(l_index,3);
	
	}	
	
	function getFileLoc(l_index) {
	
	      l_filename = getFilename(l_index);
	      
	      l_filename = './hashflash/' + getImageYear(l_index) + '/' + l_filename;
	      
	      return l_filename;
	
	}	
	
	function getThumbFileLoc(l_index) {
	
	      l_filename = getFilename(l_index);
	      
	      l_filename = './hashflash/' + getImageYear(l_index) + '/thumbs/tmb_' + l_filename;
	      
	      return l_filename;
	
	}
	
	function getCap1(l_index) {
	
	      return getImageDetails(l_index,4);
	
	}	

	function getCap2(l_index) {
	
	      return getImageDetails(l_index,5);
	
	}
		
	
	if (pToGet == "getReq") {

	   	return getReq();
	}	
	
	if (pToGet == "getYearCount") {
	
	   	return getYearCount();
	}
	
	if (pToGet == "getImageCount") {
	
	   	return getImageCount();
	}	
	
	if (pToGet == "getYear")  {
		
		return getYear(psub);
	}

	if (pToGet == "getYearDesc")  {
		
		return getYearDesc(psub);
	}
	
	if (pToGet == "getImageYear")  {
		
		return getImageYear(psub);
	}
	
	if (pToGet == "getImageThumbWidth")  {
		
		return getImageThumbWidth(psub);
	}	

	if (pToGet == "getLocation")  {
		
		return getLocation(psub);
	}	

	if (pToGet == "getFileLoc")  {
		
		return getFileLoc(psub);
	}
	
	if (pToGet == "getThumbFileLoc")  {
			
		return getThumbFileLoc(psub);
	}

	if (pToGet == "getCap1")  {
		
		return getCap1(psub);
	}

	if (pToGet == "getCap2")  {
		
		return getCap2(psub);
	}
		
}