function hideworksection(divid)
	{
		document.getElementById(divid).style.display = "none";
		
	}
function showworksection(divid)
	{
		document.getElementById(divid).style.display = "block";
	}

function setcurrenttab(divid)
	{
		document.getElementById(divid).setAttribute("class", "worktypecurrent");
	}
function unsetcurrenttab(divid)
	{
		document.getElementById(divid).setAttribute("class", "worktype");	
	}

$(document).ready(function(){
	jQuery.fn.fadeIn = function(speed, easing, callback) {
	return this.animate({opacity: 'toggle'}, speed, easing, callback);
	};
		$("#fundraisingtoggler").click(function() {
		$("#fundraising").fadeIn("slow"); 
		setcurrenttab("worktypefundraising");
		hideworksection("dm");	
		hideworksection("campaigning");	
		hideworksection("awareness"); 
		hideworksection("branding");
		hideworksection("digital"); 
		hideworksection("data");
		hideworksection("socialmedia");
		hideworksection("slideshows");
		
		unsetcurrenttab("worktypedm");	
		unsetcurrenttab("worktypecampaigning");	
		unsetcurrenttab("worktypeawareness"); 
		unsetcurrenttab("worktypebranding");
		unsetcurrenttab("worktypedigital"); 
		unsetcurrenttab("worktypedata");
		unsetcurrenttab("worktypesocialmedia");
		unsetcurrenttab("worktypeslideshows");
		
		});	
		
		$("#dmtoggler").click(function() {
		$("#dm").fadeIn("slow");
		setcurrenttab("worktypedm");
		hideworksection("fundraising"); 
		hideworksection("campaigning");
		hideworksection("awareness");
		hideworksection("branding");
		hideworksection("digital");
		hideworksection("data");
		hideworksection("socialmedia");
		hideworksection("slideshows");
		
		unsetcurrenttab("worktypefundraising");	
		unsetcurrenttab("worktypecampaigning");	
		unsetcurrenttab("worktypeawareness"); 
		unsetcurrenttab("worktypebranding");
		unsetcurrenttab("worktypedigital"); 
		unsetcurrenttab("worktypedata");
		unsetcurrenttab("worktypesocialmedia");
		unsetcurrenttab("worktypeslideshows");
		
		});
		
		$("#campaigningtoggler").click(function() {
		$("#campaigning").fadeIn("slow");
		setcurrenttab("worktypecampaigning");
		hideworksection("fundraising");
		hideworksection("dm");
		hideworksection("awareness");
		hideworksection("branding");
		hideworksection("digital");
		hideworksection("data");
		hideworksection("socialmedia");
		hideworksection("slideshows");
		
		unsetcurrenttab("worktypefundraising");	
		unsetcurrenttab("worktypedm");	
		unsetcurrenttab("worktypeawareness"); 
		unsetcurrenttab("worktypebranding");
		unsetcurrenttab("worktypedigital"); 
		unsetcurrenttab("worktypedata");
		unsetcurrenttab("worktypesocialmedia");
		unsetcurrenttab("worktypeslideshows");
		
		});
		
		$("#awarenesstoggler").click(function() {
		$("#awareness").fadeIn("slow");
		setcurrenttab("worktypeawareness");
		hideworksection("fundraising");
		hideworksection("dm");
		hideworksection("campaigning");
		hideworksection("branding");
		hideworksection("digital");
		hideworksection("data");
		hideworksection("socialmedia");
		hideworksection("slideshows");
		
		unsetcurrenttab("worktypefundraising");	
		unsetcurrenttab("worktypedm");	
		unsetcurrenttab("worktypecampaigning");	
		unsetcurrenttab("worktypebranding");
		unsetcurrenttab("worktypedigital"); 
		unsetcurrenttab("worktypedata");
		unsetcurrenttab("worktypesocialmedia");
		unsetcurrenttab("worktypeslideshows");
		
		});				
		
		$("#brandingtoggler").click(function() {
		$("#branding").fadeIn("slow");
		setcurrenttab("worktypebranding");
		hideworksection("fundraising");
		hideworksection("dm");
		hideworksection("campaigning");
		hideworksection("awareness");
		hideworksection("digital");
		hideworksection("data");
		hideworksection("socialmedia");
		hideworksection("slideshows");
		
		unsetcurrenttab("worktypefundraising");	
		unsetcurrenttab("worktypedm");	
		unsetcurrenttab("worktypecampaigning");	
		unsetcurrenttab("worktypeawareness"); 
		unsetcurrenttab("worktypedigital"); 
		unsetcurrenttab("worktypedata");
		unsetcurrenttab("worktypesocialmedia");
		unsetcurrenttab("worktypeslideshows");
		
		});
		
		$("#digitaltoggler").click(function() {
		$("#digital").fadeIn("slow");
		setcurrenttab("worktypedigital");
		hideworksection("fundraising");
		hideworksection("dm");
		hideworksection("campaigning");
		hideworksection("awareness");
		hideworksection("branding");
		hideworksection("data");
		hideworksection("socialmedia");
		hideworksection("slideshows");
		
		unsetcurrenttab("worktypefundraising");	
		unsetcurrenttab("worktypedm");	
		unsetcurrenttab("worktypecampaigning");	
		unsetcurrenttab("worktypeawareness"); 
		unsetcurrenttab("worktypebranding");
		unsetcurrenttab("worktypedata");
		unsetcurrenttab("worktypesocialmedia");
		unsetcurrenttab("worktypeslideshows");
		
		});
		
		$("#datatoggler").click(function() {
		$("#data").fadeIn("slow");
		setcurrenttab("worktypedata");
		hideworksection("fundraising");
		hideworksection("dm");
		hideworksection("campaigning");
		hideworksection("awareness");
		hideworksection("branding");
		hideworksection("digital");
		hideworksection("socialmedia");
		hideworksection("slideshows");
		
		unsetcurrenttab("worktypefundraising");	
		unsetcurrenttab("worktypedm");	
		unsetcurrenttab("worktypecampaigning");	
		unsetcurrenttab("worktypeawareness"); 
		unsetcurrenttab("worktypebranding");
		unsetcurrenttab("worktypedigital"); 
		unsetcurrenttab("worktypesocialmedia");
		unsetcurrenttab("worktypeslideshows");
		
		});
		
		$("#socialmediatoggler").click(function() {
		$("#socialmedia").fadeIn("slow");
		setcurrenttab("worktypesocialmedia");
		hideworksection("fundraising");
		hideworksection("dm");
		hideworksection("campaigning");
		hideworksection("awareness");
		hideworksection("branding");
		hideworksection("digital");
		hideworksection("data");
		hideworksection("slideshows");
		
		unsetcurrenttab("worktypefundraising");	
		unsetcurrenttab("worktypedm");	
		unsetcurrenttab("worktypecampaigning");	
		unsetcurrenttab("worktypeawareness"); 
		unsetcurrenttab("worktypebranding");
		unsetcurrenttab("worktypedigital"); 
		unsetcurrenttab("worktypedata");
		unsetcurrenttab("worktypeslideshows");
		
		});
		
		$("#slideshowstoggler").click(function() {
		$("#slideshows").fadeIn("slow");
		setcurrenttab("worktypeslideshows");
		hideworksection("fundraising");
		hideworksection("dm");
		hideworksection("campaigning");
		hideworksection("awareness");
		hideworksection("branding");
		hideworksection("digital");
		hideworksection("data");
		hideworksection("socialmedia");
		
		unsetcurrenttab("worktypefundraising");	
		unsetcurrenttab("worktypedm");	
		unsetcurrenttab("worktypecampaigning");	
		unsetcurrenttab("worktypeawareness"); 
		unsetcurrenttab("worktypebranding");
		unsetcurrenttab("worktypedigital"); 
		unsetcurrenttab("worktypedata");
		unsetcurrenttab("worktypesocialmedia");
		
		});
		
		$("#upcomingtoggler").click(function() {
		$("#upcoming").fadeIn("slow");
		setcurrenttab("eventtypeupcoming");
		hideworksection("past");
		
		unsetcurrenttab("eventtypepast");	
		
		});
		
		$("#pasttoggler").click(function() {
		$("#past").fadeIn("slow");
		setcurrenttab("eventtypepast");
		hideworksection("upcoming");
		
		unsetcurrenttab("eventtypeupcoming");	
		
		});
});
