I want to convert an input date in the form of dd/mm/yyyy
to the MySQL format which is yyyy-mm-dd
.
I was trying to use date('Y-m-d', strtotime($_POST['date']))
but the problem is that the output is always Y-d-m,
I think because it considers my 2nd argument to be mm/dd/yyyy
.
Bunu nasıl çözerim?