<?php $date = DateTime::createFromFormat('j-M-Y', '02-Jan-2024'); echo $date->format('Y-m-d'); ?>