$(document).ready(function () {
	var res = cur_date.split("-");
	$('#calFront').jCal({
		day:		new Date(res[0], (res[1]-1), res[2]),
		ml:			['Январь', 'Февраль', 'Март', 'Апрель', 'Май', 'Июнь', 'Июль', 'Август', 'Сентябрь', 'Октябрь', 'Ноябрь', 'Декабрь'],
		dow:		['Пн', 'Вт', 'Ср', 'Чт', 'Пт', 'Сб', 'Вс'],
		dayOffset:		1,											// 0=week start with sunday, 1=week starts with monday
		dCheck:		function (day) {
				
				if (day.getFullYear() == res[0] && (day.getMonth()+1) == res[1] && day.getDate() == res[2]) return false;
				return true;
			},
		callback:	function (day, days) {
				t_day = day.getDate();
				t_month = (day.getMonth()+1);
				if (t_month < 10) t_month = '0' + t_month;
				if (t_day < 10) t_day = '0' + t_day;
				var url=calendar_front_url + '/date/' + day.getFullYear() + '-' + t_month + '-' + t_day;
				location.href = url;
				return true;
			}
	});
});
