Slight change to javascript function within an availability calandar
$30-100 USD
Concluído
Publicado há mais de 16 anos
$30-100 USD
Pago na entrega
We need a experienced javascript/php programmer to make a small adjustment to an availability calendar.
javascript skills essential we could provide php support.
[login to view URL];task=view&id=261&Itemid=22
The calendar is fully functional and working, it runs off a database to display availability for property. It allows you to select 2 dates then runs an ajax request to return a price.
Each cell of the calendar has a colour red for booked white for bookable. We need to display the change over days as half red half white and they need to be able to be selected as either the first or last day of someones holiday. The way we have written it only defines valid dates and invalid dates. We need some one to write a function that identifies and references change over days, check to see if its a end date or a start date, output a different image for the cell, allow the date to be clickable. It was designed fro users to be able to select nights they wished to stay instead of days.
below is one of the js functions.
// {{{ isDateWithinValidRange()
/**
* Return true if given date is within valid date range.
*
* @param Array inputDate-Associative array representing a date, keys in array:year,month and day
* @return Boolean dateWithinRange
*@public
*/
isDateWithinValidRange:function(inputDate)
{
if(this.invalidDateRange.length==0)return true;
var month=inputDate.month+'';
if(month.length==1)month='0'+month;
var day=inputDate.day+'';
if(day.length==1)day='0'+day;
var dateToCheck=inputDate.year+month+day;
for(var no=0;no<[login to view URL];no++){
if(![login to view URL][no].fromDate&&[login to view URL][no].toDate>=dateToCheck)return false;
if(![login to view URL][no].toDate&&[login to view URL][no].fromDate<=dateToCheck)return false;
if([login to view URL][no].fromDate<=dateToCheck&&[login to view URL][no].toDate>=dateToCheck)return false;
}
return true;
}
,
Hi,
I am new bie for GAF, but highly experienced programmer in javascript with a good knowledge of php also. I think it will be a child's play for me.
Regards
$75 USD em 2 dias
4,9 (18 avaliações)
4,6
4,6
2 freelancers estão ofertando em média $63 USD for esse trabalho