How to change the date format in the date field as a select list? On user registration page, I have added a date field in select list.

In the manage form display tab, I can set the order of the dropdown fields like day/month/year or month/day/year But I am unable to change the format of the date.

Currently in the day dropdown, it is displaying like 1, 2, 3 and I want to change it to 01, 02, 03. Similarly in the month dropdown, it is displaying like, Jan, Feb and I want to display it like January, February.

Is this possible?
If you want to alter the way this component is shown globally, you can implement hook_preprocess_datetime_form(), eg. like this:

function mymodule_preprocess_datetime_form(&amp;$variables) {
  // Ensure there's a month field and it's a select.
  if (isset($variables["content"]["month"]) &amp;&amp; $variables["content"]["month"]['#type'] === 'select') {
    foreach ($variables["content"]["month"]['#options'] as $monthNum =&gt; $label) {
      if ($monthNum) {
        // Convert month number to unabbreviated name.
        $dateObj = DateTime::createFromFormat('!m', $monthNum);
        $monthName = $dateObj-&gt;format('F');
        $variables["content"]["month"]['#options'][$monthNum] = $monthName;
  }
}


}

The code for the day select will be similar.