function loadMonth() {
	new Ajax.Updater('eventsview', '/calendar/monthView.html', { method: 'get' });
}

function loadDay() {
	new Ajax.Updater('eventsview', 'calendar/dayView.html', { method: 'get' });
}

function loadEvents() {
	new Ajax.Updater('eventsview', 'calendar/eventsView.html', { method: 'get' });
}

function resetTabs() {
	document.getElementById("CalendarInfo").className='';
	document.getElementById("EventList").className='';
	document.getElementById("CalendarStatistics").className='';
	document.getElementById("ShareCalendar").className='';
}

function loadCalendarInfo() {
	new Ajax.Updater('tabContent', 'calendar/calendarInfo.html', { method: 'get',parameters:'ajx=1',evalScripts: true });
	resetTabs();
	document.getElementById("CalendarInfo").className='active';
}

function loadEventList() {
	new Ajax.Updater('tabContent', 'calendar/eventList.html', { method: 'get',parameters:'ajx=1' });
	resetTabs();
	document.getElementById("EventList").className='active';
}


function loadCalendarReviews() {
	new Ajax.Updater('tabContent', 'calendar/calendarReviews.html', { method: 'get',parameters:'ajx=1',evalScripts: true  });
	resetTabs();
	document.getElementById("CalendarReviews").className='active';
}

function loadOwnerStatistics() {
	new Ajax.Updater('tabContent', 'calendar/ownerStatistics.html', { method: 'get' });
	resetTabs();
	document.getElementById("OwnerStatistics").className='active';
}

function loadCalendarStatistics() {
	new Ajax.Updater('tabContent', 'calendar/calendarStatistics.html', { method: 'get',parameters:'ajx=1' });
	resetTabs();
	document.getElementById("CalendarStatistics").className='active';
}

function loadPublishCalendarInfo() {
	new Ajax.Updater('tabContent', 'calendar/publishCalendarInfo.html', { method: 'get' });
	resetTabs();
	document.getElementById("PublishCalendarInfo").className='active';
}

function loadShareCalendar() {
	new Ajax.Updater('tabContent', 'calendar/calendarShare.html', { method: 'get',evalScripts: true  });
	resetTabs();
	document.getElementById("ShareCalendar").className='active';
}

function loadDayByDate(day,month,year){
	params = 'day='+day;
	params += '&month='+month;
	params += '&year='+year;
	new Ajax.Updater('eventsview', 'calendar/dayView.html', { method: 'post', parameters: params});
}
function loadMonthByDate(month,year){
	params2 = 'month='+month;
	params2 += '&year='+year;
	new Ajax.Updater('eventsview', 'calendar/monthView.html', { method: 'post', parameters: params2});
}

function loadCalendarReviewsById(calendar_id){
	new Ajax.Updater('eventsview', 'calendar/calendarReviews.html', { method: 'get',parameters:'calendar='+calendar_id,evalScripts: true });
	resetTabs();
}

function loadTimezoneList(elementname){
	new Ajax.Updater(elementname,'/fetchTimezoneList.html',{method:'get'});
}

function loadCountryList(){
	new Ajax.Updater('calCountryDropDownList','/fetchCountryList.html',{method:'get'});
}

function loadSubCategoryList(category_id,subcategory_id) {
	new Ajax.Updater('subCategoryList','/fetchSubCategoryList.html',{method: 'get',parameters:'category='+category_id+'&subcategory='+subcategory_id,evalScripts:true });
}

function addDownload(type) {
	new Ajax.Request('getDownload.html', {method:'get',parameters:'type='+type,asynchronous:false});
}


