jQuery(function(){
	jQuery('input[placeholder], textarea[placeholder]').placeholder();
});

function mycarousel_initCallback(carousel)
{
    // Disable autoscrolling if the user clicks the prev or next button.
    carousel.buttonNext.bind('click', function() {
        carousel.startAuto(0);
    });

    carousel.buttonPrev.bind('click', function() {
        carousel.startAuto(0);
    });

    // Pause autoscrolling if the user moves with the cursor over the clip.
    carousel.clip.hover(function() {
        carousel.stopAuto();
    }, function() {
        carousel.startAuto();
    });
};
function showClock()
{
	//var now=new Date();
	//now.setHours(now.getHours(), now.getMinutes(), now.getSeconds());
	//var nh = now.getHours();
	//if (nh < 10) nh = "0" + nh;
	//var nm = now.getMinutes();
	//if (nm < 10) nm = "0" + nm;
	//var ns = now.getSeconds();
	//if (ns < 10) ns = "0" + ns;
	//document.getElementById('clock').innerHTML = ""+nh+":"+nm+":"+ns;
	$('#clock').load('/time.php');
	setTimeout("showClock()", 30000);
}

	$(document).ready(function(){
	              function relPage() {
				      location.reload();
				    }


				 jQuery('#mycarousel1').jcarousel({
					auto: 5,
					wrap: 'last',
					initCallback: mycarousel_initCallback
				});

				 jQuery('#mycarousel2').jcarousel({
					auto: 5,
					wrap: 'last',
					initCallback: mycarousel_initCallback
				});

				 jQuery('#mycarousel3').jcarousel({
					auto: 5,
					wrap: 'last',
					initCallback: mycarousel_initCallback
				});

				 jQuery('#mycarousel4').jcarousel({
					auto: 5,
					wrap: 'last',
					initCallback: mycarousel_initCallback
				});

				 jQuery('#mycarousel5').jcarousel({
					auto: 5,
					wrap: 'last',
					initCallback: mycarousel_initCallback
				});

				$(".blocks_row .item").height($(".blocks_row .item").parent().height()-40);

				$("area[rel^='prettyPhoto']").prettyPhoto();
				$(".gallery:first a[rel^='prettyPhoto']").prettyPhoto({animation_speed:'normal',theme:'facebook',slideshow:false, autoplay_slideshow: false});
				$(".gallery:gt(0) a[rel^='prettyPhoto']").prettyPhoto({animation_speed:'fast',slideshow:false, hideflash: true});
				$("#custom_content a[rel^='prettyPhoto']:first").prettyPhoto({
				custom_markup: '<div id="map_canvas" style="width:260px; height:265px"></div>',
				changepicturecallback: function(){ initialize(); }
				});
				$("#custom_content a[rel^='prettyPhoto']:last").prettyPhoto({
				custom_markup: '<div id="bsap_1259344" class="bsarocks bsap_d49a0984d0f377271ccbf01a33f2b6d6"></div><div id="bsap_1237859" class="bsarocks bsap_d49a0984d0f377271ccbf01a33f2b6d6" style="height:260px"></div><div id="bsap_1251710" class="bsarocks bsap_d49a0984d0f377271ccbf01a33f2b6d6"></div>',
				changepicturecallback: function(){ _bsap.exec(); }
				});

	});

