$(function() { 
	//applyDropDownMenuJS('.dropdown');
	
	//Transparency fix for pngs in ie	
	$('#labelNav img').pngFix();
	$('#btnSunParasol img').pngFix();

	//fade out flower tags.
         $('#labelNav img').live({
                mouseover:function(){
                    $(this).fadeTo("fast",0.8);
                },
                mouseout:function(){
                    	$(this).fadeTo("fast",1);
                }
            }
	);		
	
	$('#btnSunParasol img').hover(
		function(){
			$(this).fadeTo("fast",0.8);
		},
		function(){
			$(this).fadeTo("fast",1);
	});
	
	
	// tag navigation slider
	$('#labelNav').bxSlider({		
		auto: false,
		auto_controls: false,
		pager: false,
		speed: 1000, 	
		pause: 5000	,
		nextText: 'Scroll Right',
		prevText: 'Scroll Left',
		infiniteLoop:true,	
		displaySlideQty: 6,
		moveSlideQty: 3
	});			
	
	
	// search box text
	 $("#txtSeachQuery").focusin(function() { 
		$(this).val("") 
	 }); 
	 
	 $("#txtSearchQuery").focusout(function() {
	 	$(this).val("Search");	
	 });
	
});


//Set up animation for drop down menu
function applyDropDownMenuJS(menuJQSelector){
	 $(menuJQSelector+" li").hover(
        function() {
            $(this).children("ul").stop().hide().css("height","auto").slideDown("slow");
        },
        function() {
        $(this).children("ul").stop().slideUp("slow");
    });	
}


  function recordOutboundLink(link, category, action) {
    _gat._getTrackerByName()._trackEvent(category, action);
    setTimeout('document.location = "' + link.href + '"', 100);
  }

//PNG fix jquery extension
$.fn.pngFix = function() {
  if (!$.browser.msie || $.browser.version >= 9) { return $(this); }

  return $(this).each(function() {
    var img = $(this),
        src = img.attr('src');

    img.attr('src', url+'media/gfx/transparent.gif')
        .css('filter', "progid:DXImageTransform.Microsoft.AlphaImageLoader(enabled='true',sizingMethod='crop',src='" + src + "')");
  });
};

