var ImgArray = Array("/wp-content/themes/twentyten/images/header.jpg",
"/wp-content/themes/twentyten/images/header_02.jpg",
"/wp-content/themes/twentyten/images/header_03.jpg",
"/wp-content/themes/twentyten/images/header_04.jpg",
"/wp-content/themes/twentyten/images/header_05.jpg",
"/wp-content/themes/twentyten/images/header_06.jpg",
"/wp-content/themes/twentyten/images/header_07.jpg",
"/wp-content/themes/twentyten/images/header_08.jpg",
"/wp-content/themes/twentyten/images/header_09.jpg",
"/wp-content/themes/twentyten/images/header_10.jpg");
var img = Array();
for (i=0;i<ImgArray.length; i++){
img[i] = new Image();
img[i].src = ImgArray[i];
}

			$(window).load(function(){
				var counter = 1;
				$("#header_into").width($("#SlideShow").width());
				$("#header_into").height($("#SlideShow").height());
				setInterval(function(){
					$("#header_into").css({'background-image' : 'url('+$("#SlideShow").attr("src")+')'});
					var src=img[counter % img.length].src;
					$("#SlideShow").hide().attr("src",src).fadeIn(3000);
					counter++;
				},5000);
			});
                    
                    
                    
        $(document).ready(function(){
			$(".dop_info_link").click(function(){
				$("#dopcontent"+$(this).attr("id").substr(8)).toggle();
				return false;
			});
            $("#open_menu").click(function () {
            $("#menu-ob-uzbekistane").toggle("slow");

});

        $("#open_down").click(function () {
            $(".down").toggle("slow");
            $(".bottom_block_down").toggle("slow");
  });
        $("#open_up").click(function () {
              $(".up").toggle("slow");
              $(".bottom_block_up").toggle("slow");

 
});

});


    function ImgCheckbox(imgId, inputId, imgOn, imgOff) {
        this.imgOn   = imgOn
        this.imgOff  = imgOff
        this.image   = document.getElementById(imgId)
        this.input   = document.getElementById(inputId)
        this.preload_imgOn      = new Image()
        this.preload_imgOn.src  = imgOn
        this.preload_imgOff     = new Image()
        this.preload_imgOff.src = imgOff
        this.input.style.display = "none"
        this.image.style.display = "inline"
    
    }
    ImgCheckbox.prototype.setState = function(state) {
        this.input.checked     = state
        this.image.src   = state ? this.imgOff : this.imgOn
    }
    ImgCheckbox.prototype.flip = function() {
        this.setState(!this.input.checked)
    }



