$(document).ready(function(){
	var div='';
	var title;
	var content;
	var x;
	$('.piclenselink').remove();
	$('.ngg-clear').remove();
	$('#s2 .ngg-gallery-thumbnail-box a').each(function() {
		title = $('img',this).attr('title');
		content = $(this).attr('title');
		div = '<span class="slider_desc">';
		div += '<p class="section_title">'+title+'</p>';
		div += '<p class="section_content">'+content+'</p>';
		div += '</span>';
		x = $(this).html();
		x = div + x;
		$(this).html(x);
		$('img',this).width(726);
		$('img',this).height(270);
		var s1 = $('img',this).attr('src');
		//alert(s1);
		str = s1.replace("thumbs/",'');
		str = str.replace("thumbs_",'');
		$('img',this).attr('src',str);
	});
	var name='';
	$('.list li a').each(function(){
		
		$(this).click(function() {
			$('.list li .active').removeClass('active');
			$(this).addClass('active');
			$('.the_current_page').removeClass('the_current_page');
			name = $(this).attr('name');
			$('.'+name).addClass('the_current_page');
		});
	
	});
	var color = '';
	var i = 0;
	$('.navigation li a').each(function() {
		i++;
		if ($(this).hasClass('active')) {
			switch(i)
			  {
						   case 1: $(this).parent().css('background-color','#231f20');break;
						   case 2: $(this).parent().css('background-color','#BE1E2D');break;
						   case 3: $(this).parent().css('background-color','#27AAE1');break;
						   case 4: $(this).parent().css('background-color','#662D91');break;
						   case 5: $(this).parent().css('background-color','#F7941E');break;
						   case 6: $(this).parent().css('background-color','#8DC63F');break;
			  }
			color = $(this).parent().css('backgroundColor');
			//alert(color);
		}
		 
	});
	
	$('.slider_services').css('background-color',color);
	
	var username = $('#username').val();
	var pass = $('#password').val();
	
	$('#username').focus(function() {
		if ($(this).val()==username) {
			$('#username').val('');
		}
	});
	
	$('#password').focus(function() {
		if ($(this).val()==pass) {
			$('#password').val('');
		}
	});
	
	$('#username').blur(function() {
		if ($(this).val()=='') {
			$(this).val(username);
		}
	});
	
	$('#password').blur(function() {
		if ($(this).val()=='') {
			$(this).val(pass);
		}
	});
	
});

$(window).bind('load',function(){
	
	
});
