var secs
					var timerID = null
					var timerRunning = false
					var delay = 1000
								
					function InitializeTimer()
					{						
						// Set the length of the timer, in seconds
						secs = 30 // this number should be number of seconds for each slide x number of slides - currently: 6 sec x 5 slides
						StopTheClock()
						StartTheTimer()
						selectFeatureA() 
						document.getElementById("play").className="playOn";
						document.getElementById("pause").className="pause";
					}
					
					function StopTheClock()
					{
						if(timerRunning){
						clearTimeout(timerID)
						timerRunning = false
						document.getElementById("play").className="play";
						document.getElementById("pause").className="pauseOn";
						}
					}
					
					function StartTheTimer()
					{	   
						clearTimeout(timerID)

						if (secs==24) // count down in intervals of seconds
						{	
							selectFeatureB();
							secs = secs - 1
							timerRunning = true
							timerID = self.setTimeout("StartTheTimer()", delay)
						}
						else if (secs==18)
						{	
							selectFeatureC();
							secs = secs - 1
							timerRunning = true
							timerID = self.setTimeout("StartTheTimer()", delay)
						}
						else if (secs==12)
						{	
							selectFeatureD();
							secs = secs - 1
							timerRunning = true
							timerID = self.setTimeout("StartTheTimer()", delay)
						}
						else if (secs==6)
						{	
							selectFeatureE();
							secs = secs - 1
							timerRunning = true
							timerID = self.setTimeout("StartTheTimer()", delay)
						}
						else if (secs==0)
						{	
							selectFeatureA();
							secs = 30 // this number needs to eaqual the secs in InitializeTimer() above - bring it back to the top
							secs = secs - 1
							timerRunning = true
							timerID = self.setTimeout("StartTheTimer()", delay)
						}
						else
						{
							//self.status = secs
							secs = secs - 1
							timerRunning = true
							timerID = self.setTimeout("StartTheTimer()", delay)
						}
					}
					
					//the following functions are for the five numbers individually
					
					function selectFeatureA() 
					{		featureNav.className="featureA"; //selects nav
							targetImage.setAttribute("src",F1_img); //image url
							targetLinkA.setAttribute("href",F1_link); // href link for image  
							targetLinkB.setAttribute("href",F1_link); // href link for 'full story'
							targetLinkC.setAttribute("href",F1_link); // href link for title
							targetPhotoCredit.firstChild.nodeValue = F1_photocredit; // photo credit
							targetSource.firstChild.nodeValue = F1_source; // source
							targetHeadline.firstChild.nodeValue = F1_headline; // headline
							targetCaption.firstChild.nodeValue = F1_caption; // caption
							
					}
					
					
					function selectFeatureB() 
					{		featureNav.className="featureB"; //selects nav
							targetImage.setAttribute("src",F2_img); //image url
							targetLinkA.setAttribute("href",F2_link); // href link for image  
							targetLinkB.setAttribute("href",F2_link); // href link for 'full story'
							targetLinkC.setAttribute("href",F2_link); // href link around title
							targetPhotoCredit.firstChild.nodeValue = F2_photocredit; // photo credit
							targetSource.firstChild.nodeValue = F2_source; // source
							targetHeadline.firstChild.nodeValue = F2_headline; // headline
							targetCaption.firstChild.nodeValue = F2_caption; // caption
							
					}
					
					function selectFeatureC() 
					{		featureNav.className="featureC"; //selects nav
							targetImage.setAttribute("src",F3_img); //image url
							targetLinkA.setAttribute("href",F3_link); // href link for image  
							targetLinkB.setAttribute("href",F3_link); // href link for 'full story'
							targetLinkC.setAttribute("href",F3_link); // href link around title
							targetPhotoCredit.firstChild.nodeValue = F3_photocredit; // photo credit
							targetSource.firstChild.nodeValue = F3_source; // source
							targetHeadline.firstChild.nodeValue = F3_headline; // headline
							targetCaption.firstChild.nodeValue = F3_caption; // caption
							
					}
					
					function selectFeatureD() 
					{		featureNav.className="featureD"; //selects nav
							targetImage.setAttribute("src",F4_img); //image url
							targetLinkA.setAttribute("href",F4_link); // href link for image  
							targetLinkB.setAttribute("href",F4_link); // href link for 'full story'
							targetLinkC.setAttribute("href",F4_link); // href link around title
							targetPhotoCredit.firstChild.nodeValue = F4_photocredit; // photo credit
							targetSource.firstChild.nodeValue = F4_source; // source
							targetHeadline.firstChild.nodeValue = F4_headline; // headline
							targetCaption.firstChild.nodeValue = F4_caption; // caption

							
					}
					
					function selectFeatureE() 
					{		featureNav.className="featureE"; //selects nav
							targetImage.setAttribute("src",F5_img); //image url
							targetLinkA.setAttribute("href",F5_link); // href link for image  
							targetLinkB.setAttribute("href",F5_link); // href link for 'full story'
							targetLinkC.setAttribute("href",F5_link); // href link around title
							targetPhotoCredit.firstChild.nodeValue = F5_photocredit; // photo credit
							targetSource.firstChild.nodeValue = F5_source; // source
							targetHeadline.firstChild.nodeValue = F5_headline; // headline
							targetCaption.firstChild.nodeValue = F5_caption; // caption
							
					}