$(document).ready(function(){
	if($('#menu').length){
		$('#menu li').each(function(){		
			var link = $('a', this).attr('href');
		
			$(this).click(function(){
				document.location = base + link;
			});
		});
	};	
});


$(document).ready(function() {

  var $input1 = $('.cw2 .text input, .cw26 .text input');
  var $label1 = $('.cw2 .text label, .cw26 .text label');
  
  if ($input1.val()){
    $label1.hide();
  }

  $input1.focus(function(){
	
    $label1.hide();
		
  }).blur(function(){
    
		if (this.value == ''){
      $label1.show();
    }
		
  });
  
  $label1.click(function() {
    $input1.trigger('focus');
  });
	
	
	var $input2 = $('.cw2 .password input, .cw26 .password input');
  var $label2 = $('.cw2 .password label, .cw26 .password label');
  
  if ($input2.val()){
    $label2.hide();
  }

  $input2.focus(function(){
	
    $label2.hide();
		
  }).blur(function(){
    
		if (this.value == ''){
      $label2.show();
    }
		
  });
  
  $label2.click(function() {
    $input2.trigger('focus');
  });
	
});


$(document).ready(function() {
    $('.cw18 .g ul').jcarousel({
			scroll: 4
		});
});

//content slider
$(document).ready(function(){	
			$('.cw31 .g .slider, .cw34 .g .slider, .cw7 .g .slider, .cw36 .g .slider, .cw9 .w. .slider').easySlider();
});


function gup( name )
{
  name = name.replace(/[\[]/,"\\\[").replace(/[\]]/,"\\\]");
  var regexS = "[\\?&]"+name+"=([^&#]*)";
  var regex = new RegExp( regexS );
  var results = regex.exec( window.location.href );
  if( results == null )
    return "";
  else
    return results[1];
}

$(document).ready(function(){

  if (gup('country')) {

    $('#Country').attr("disabled", true);

  }

});
