﻿$(document).ready(function() {

    //$('.tab').click(function() {
      //  if ($(this).is("active")) {
        //    return;
        //}

        //var classy = $(this).attr("class").split(" ")[1];
        //var innerhtml = $('.content.' + classy).text();

        //$('#holder').html(innerhtml).slideDown("slow");

        //$('.tab').removeClass('active');
        //$(this).addClass('active');
    //});
	
	$(".tabContent").hide();
	$("#clients").show();

	  $(".tab").click(function() {
		 $(".tab").removeClass("active");
		 $(this).addClass("active");
		 $(".tabContent").hide();
		 var currentTab = $(this).attr("href");
		 $(currentTab).show();
		 return false;
	  });


    var url = document.location.toString();

    if (url.match(/#([a-z])/)) {
        //There is a hash, followed by letters in it, therefore the user is targetting a page.  
        var split = url.split("#")[1];
        $('.tab.' + split).click();
    }
    else {
        $('.tab:first').click();
    }
});
