$(document).ready (function(){
	
	$("table#company th:last, table#company td:last, ul#sidebar li:last, ul#submenu li:last").addClass("last");
	$(".menu ul li:last, #ebpteam_list_management dd:last, ul#testimonials li:last, .servicePortfolio .port_thumb:last, #tabContents table tr:last").addClass("last");
	$("#tabContents table thead th:first").addClass("first");
	$("#tabContents table tbody tr:even").addClass("even");
	$("#tabContents table tbody tr:odd").addClass("odd");
	/*$('#tab1 table tr td').each(function(){
											  $("#tab1 table tr td:last").addClass("last");
		
		});*/
	
	$('.port_thumb').each(function(j)
								   {
									   
									 	
										if(++j % 3 == 0 ){
											$(this).addClass('last'); 
											
											}
									   
								   });
	});
		$(document).ready(function(){	
			$("#slider").easySlider({
    auto: true,
    continuous: true,    
    numeric: true,
pause : 5000
   });
			$("#slider2").easySlider({ 
			auto: true,
			
				continuous: true,
				nextId: "slider1next",
				prevId: "slider1prev",
				numeric: false,
				pause:5000

			});
		});	

function slideSwitch() {
    var $active = $('#slideshow img.active');

    if ( $active.length == 0 ) $active = $('#slideshow img:last');

    var $next =  $active.next().length ? $active.next()
        : $('#slideshow img:first');

    $active.addClass('last-active');

    $next.css({opacity: 0.0})
        .addClass('active')
        .animate({opacity: 1.0}, 1000, function() {
            $active.removeClass('active last-active');
        });
}

$(function() {
    setInterval( "slideSwitch()", 5000 );
});
