I want to convert javascript date Mon Jun 23 2014 16:17:05 GMT+0530 (India Standard Time) into PHP datetime. I tried
echo date('Y-m-d h:i:s', strtotime($expire_time));
where $expire_time is Mon Jun 23 2014 16:17:05 GMT+0530 (India Standard Time) but it is giving 1970-01-01 12:00:00.
Please help.
toString, you should usetoISOStringto get a standard date format (which is well recognized by phpstrtotime).