// JavaScript Document
$(document).ready(function(){  

  mySelectHref=  $("li.selected a");
	if(mySelectHref.length)
	{
		mySelectHref.removeAttr('href');
	}
	
	var d = new Array("Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday");
	var m = new Array("Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sept","Oct","Nov","Dec");
	var now = new Date();
	
	dateP = document.getElementById('date');
	dateP.innerHTML = "" + now.getDate() + " " + m[now.getMonth()] + " " + now.getFullYear() + "&nbsp;";
		
	 // Simple tabContent for product details  
	
  showhide = function(containerId) {

    var index = -1;
    var current = 0;
    var effectDuration = 600;

		var container = $(containerId);

    $('#tabs LI A',container).each(function() 
		{   
	
      index++;  

      $(this)
        .attr('tabIndex', index)
				.css({cursor:'pointer'})
        .click(function(event) 
				{
          //event.preventDefault();
          newIndex = $(this).attr('tabIndex');
	
					if(newIndex == current) return;
					
					$(this).css({backgroundPositionY:'bottom'});
					
					$('.mid:eq('+current+')',container).hide();
					
					$('.#tabs LI A:eq('+current+')',container).css({backgroundPositionY:'top'});
					
					$('.mid:eq('+newIndex+')',container).show();
					
          current = newIndex;
        })
    });
		
		$('.mid:eq(0)', container).show();
							$('.#tabs LI A:eq(0)',container).css({backgroundPositionY:'bottom'});
		$('.mid:gt(0)', container).hide();
							$('.#tabs LI A:gt(0)',container).css({backgroundPositionY:'top'});
	

  };
	
	new showhide('.tab_hero');

	$("a[href$=pdf]").each(function(){
		$(this).attr('target', '_blank');
		$(this).addClass("pdf");
	});

	i=0;
															
	$('.list').each(function(){  
		(++i%2)?$(this).addClass("odd"):$(this).addClass("even");
	});		

	if(location.href.indexOf('visiting_us.html') != -1)
	{
		$("table:first tr:odd").addClass("odd");
		$("table:first tr:even").addClass("even");
  }			
	
	

	
/*alert(	);*/
/*main_menu
thickbox
<a rel="lightbox" href="../pop-up-map.php" target="_blank">*/



});