
$(document).ready(function(){

	$("ul.subnav").parent().find("a:first").append("<span class='dropdownIndicator'>&nbsp;</span>"); //Only shows drop down trigger when js is enabled - Adds empty span tag after ul.subnav
	
	//	$("ul.topnav li a span span.dropdownIndicator").mouseover(function() { //When trigger is clicked...
	$("ul.topnav li").mouseover(function() { //When trigger is mousedover...
		
		//Following events are applied to the subnav itself (moving subnav up and down)
		$(this).find("ul.subnav").slideDown('fast').show(); //Drop down the subnav on click
		
		$(this).hover(function() {
		
		}, function(){	
			
			$(this).parent().find("ul.subnav").slideUp('fast'); //When the mouse hovers out of the subnav, move it back up

		});

		
		//Following events are applied to the trigger (Hover events for the trigger)
		}).hover(function() { 
			$(this).find("a:first").addClass("active2"); // add a class so the parent nav stays selected
		}, function(){	//On Hover Out
			$(this).find("a:first").removeClass("active2"); //On hover out, remove class "subhover"		
	});

});

