jQuery(document).ready(function($){
	
if($('#mainbanner').length != 0){
	$('#mainbanner').crossSlide({
		sleep: 3,
		fade: 1
	}, [
		{ src: webURL + 'images/topbanner/home1.jpg' },
		{ src: webURL + 'images/topbanner/home2.jpg' },
                { src: webURL + 'images/topbanner/home3.jpg' }
	]);}





           if ($(".date-pick").length > 0){
		$(function() {
			$('.date-pick').datepicker({
				showOtherMonths: true, 
				selectOtherMonths: true,
				minDate:0 , 
				showOn: 'button', 
				buttonImage: webURL + 'images/calendar.jpg',
				buttonImageOnly: true
			});
		
			if (currentLang == 'el') {
				$('.date-pick').datepicker('option', $.datepicker.regional['el']);
			} else {
				$('.date-pick').datepicker('option', $.datepicker.regional['en-GB']);
			}			
		});
		
		var today = new Date();
		today.setDate(today.getDate()+1);
		var todayDate = '' + today.getDate();
		var todayDateStr = ( todayDate.length==1 ? '0'+todayDate : todayDate );
		var todayMonth = '' + (today.getMonth()+1);
		var todayMonthStr = ( todayMonth.length==1 ? '0'+todayMonth : todayMonth );
		
		var dateInEl = document.getElementById('date-in');
		var usDateInEl = document.getElementById('eu-date-in');
		
		if (usDateInEl) {
			if (usDateInEl.value == 'unknown') {
				dateInEl.value = todayDateStr + '/' + todayMonthStr + '/' +  today.getFullYear();
				usDateInEl.name = 'usdatein';
				usDateInEl.defaultValue = 'waiting'; 
				usDateInEl.value = usDateInEl.defaultValue;
			}
		}
	}
});	

function bookingOnSubmit() {
	var dateParts = $("#date-in").val().split('/');
	document.getElementById('eu-date-in').value = $("#date-in").val();
	document.getElementById('date-in').value = dateParts[1] + '/' + dateParts[0] + '/' + dateParts[2];
	document.getElementById('eu-date-in').name = 'eudatein';
	return true;
}
				var _gaq = _gaq || [];
				_gaq.push(['_setAccount', 'UA-28070909-1']);
				_gaq.push(['_trackPageview']);
				_gaq.push(['_trackPageLoadTime']);
				
				(function() {
					var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
					ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
					var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
				})();
