peter_coop
asked on
jquery datepicker sending current date if input empty
hello
can anyone tell me why datepicker submits the current date if the input field is empty? this date field is not a compulsory field and can be used at the users discretion. many thanks.
can anyone tell me why datepicker submits the current date if the input field is empty? this date field is not a compulsory field and can be used at the users discretion. many thanks.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
thank you
ASKER
$date_parts = explode("/",$_POST['datepi
$newDate = $date_parts[2] . "-" . $date_parts[1] . "-" . $date_parts[0];
$datepicker = date('Y/m/d', strtotime($newDate));