function showcruiselineShistory(){var e=document.getElementById('Scruise_line_div').style.display;if(e=="block"){document.getElementById('Scruise_line_div').style.display="none";}else{document.getElementById('Scruise_line_div').style.display="block";}}
function countDaysOfMonth(month,year){var dd=new Date(year,month,0);return dd.getDate();}
function searchCruise(){var lpcount=document.searchForm.cruiseVendorName.length;var concatstr='';for(var i=0;i<lpcount;i++){if(document.searchForm.cruiseVendorName[i].checked==true){concatstr=concatstr+document.searchForm.cruiseVendorName[i].value+',';}}
var destination_list=document.getElementById('Sdestination_list').value;if(document.getElementById('Scruise_duration').value==''){var cruise_duration=document.getElementById('Scruise_duration').value='0-9999';}
else{var cruise_duration=document.getElementById('Scruise_duration').value;}
var monYear=document.getElementById('ScruiseMonth').value;var MY=monYear.split(' ');var cruise_month=MY[0]
var cruise_year=MY[1]
if(cruise_month==0){var d=new Date();cruise_month=d.getMonth()+1;cruise_year=d.getFullYear();}
var cruise_day1=countDaysOfMonth(cruise_month,cruise_year);window.location.href='slider2_dd.php?DestinationID='+destination_list+'&cruise_duration='+cruise_duration+'&cruise_month='+cruise_month+'&cruise_year='+cruise_year+'&cruise_day=1&cruise_month2='+cruise_month+'&cruise_year2='+cruise_year+'&cruise_day2='+cruise_day1+'&vendorid='+concatstr;}
function checkVendor()
{document.searchForm.allCruiseVendors.checked=false;}
function checkVendorAll()
{var xx=0;var len=document.searchForm.elements.length;for(xx=0;xx<len;xx++)
{document.searchForm.elements[xx].checked=false;document.searchForm.allCruiseVendors.checked=true;}}
function selectSearchInput(dest,my,dur,cl){if(cl!=""){var cls=cl.split(',');var asize=cls.length;for(var i=0;i<asize;i++){var clId='ScruiseVendorID'+cls[i];document.getElementById(clId).checked='checked';document.getElementById('SallCruiseVendors').checked='';}}else{document.getElementById('SallCruiseVendors').checked='checked';var clSize=document.searchForm.cruiseVendorName.length;for(var j=0;j<clSize;j++){document.searchForm.cruiseVendorName[j].checked=false;}}
var did='SdesId_'+dest;var myr='SMY_'+my
var duration='Sdur_'+dur;document.getElementById(did).selected='selected';document.getElementById(myr).selected='selected';document.getElementById(duration).selected='selected';}