I use the component datepicker in my php application and I want to affect the value of the datepiker component to an element of a php array like this :
<?php
if ($_SERVER["REQUEST_METHOD"] == "POST")
$wish = array("id" => $_POST["wishID"], "description" => $_POST["wish"], "due_date" => .datepicker( "getDate" ));
else
if (array_key_exists("wishID", $_GET))
$wish = mysqli_fetch_array(WishDB::getInstance()->get_wish_by_wish_id($_GET["wishID"]));
else
$wish = array("id" => "", "description" => "", "due_date" => "");
?>
but I have an error when I run this page :
Parse error: syntax error, unexpected 'getDate' (T_STRING), expecting ')' in C:\wamp\www\PhpProject1\editWish.php on line 48
and the error points on this row :
"due_date" => .datepicker( "getDate" )
how I can achieve this thanks,