$(document).ready(function() {
		
	$('#spk a').smoothScroll({
	  afterScroll: function() {
		/* location.hash = this.hash; */
	  }
	});
	
	
	var text = $('#slideshow').html();
	
		if(text != null)
		{
			text = text.replace(/<p>/ig,"");
			text = text.replace(/<\/p>/ig,"");
			text = text.replace(/<br \/>/ig,"");
			$('#slideshow').html(text);
		}
	
	
	var totalImages = 0;
	$("#slideshow")
		.before("<div class='pagination'><ul id='slidenav'>") 
		.cycle({ 
		   fx:     "fade",
		   speed:  1000, 
		   timeout: 3500, 
		   pager:  "#slidenav",
	   
		   pagerAnchorBuilder: function(idx, slide) {
			   totalImages++;
			   return "<li><a id='slideshow_link_" + totalImages + "' href='#'>" + totalImages + "</a></li>"; 
		   }
	 });

});

function removeText(theinput,checktext)
{
	if(theinput.value==checktext)
	{
		theinput.value = "";
	}
}

function replaceText(theinput,checktext)
{
	if(theinput.value=="")
	{
		theinput.value = checktext;
	}
}
