 $(document).ready(function() {
 		//$("#program").tipTip({defaultPosition:"top"});
        $(".ptop>a").click(function(){
        	$.scrollTo($("#page"), 300);
        	return false;
        });

        $(".profile .twitter").each(function(){
        	$(this).tweet({
	            username:$(this).attr("id"),
	            join_text: "auto",
	            avatar_size: 32,
	           	count: 10, 
	            auto_join_text_default: "",
	            auto_join_text_ed: "",
	            auto_join_text_ing: "",
	            auto_join_text_reply: "",
	            auto_join_text_url: "",
	            loading_text: "loading tweets..."        	
        	});
        });
        
        
        $(".next_tweet").click(function(){
        
        	if(parseFloat($(this).prev().children("li").position().top) > -1000 ){
        		$(this).prev().children("li").animate({
				    top: '-=120'
				  }, 400);
        	
        	}else{
        		$(this).prev().children("li").animate({
				    top: '0'
				}, 400);
        	}
        	return false;

        });
        
        
        $('#slider').nivoSlider({
	        effect:'sliceDown',
			slices:15,
			animSpeed:500,
			pauseTime:5000,
			startSlide:0, //Set starting Slide (0 index)
			directionNav:false, //Next & Prev
			directionNavHide:false, //Only show on hover
			controlNav:false, //1,2,3...
			controlNavThumbs:false, //Use thumbnails for Control Nav
			controlNavThumbsSearch: '.jpg', //Replace this with...
			controlNavThumbsReplace: '_thumb.jpg', //...this in thumb Image src
			keyboardNav:false, //Use left & right arrows
			pauseOnHover:true, //Stop animation while hovering
			manualAdvance:false, //Force manual transitions
			captionOpacity:0.5, //Universal caption opacity
			beforeChange: function(){},
			afterChange: function(){},
			slideshowEnd: function(){} //Triggers after all slides have been shown
		}); 
		
 });
