I have a store with Italian Language with Magento 2.3.0. In that store, I have created a calendar and I am facing some issue while selecting the date from the calendar.

My Date Format is dd/MM/yy. My expected out is "12 March 2019". But I am always getting this 12/03/2019.

    $dateFormat = $this->_localeDate->getDateFormat(\IntlDateFormatter::SHORT);
    $escapedDateFormat = preg_replace('/[^MmDdYy\/\.\-]/', '', $this->getDateFormat());
        'extra_params' => $this->isRequired() ? 'data-validate="{required:true}"' : '',
        'name' => 'expired_date',
        'id' => 'expired_date',
        'class' => $this->getHtmlClass().'required-entry',
        'value' => $this->getRequiredDate(),
        'date_format' => $this->getDateFormatVals(),
        'image' => $this->getViewFileUrl('Magento_Theme::calendar.png'),
        'change_month' => 'true',
        'change_year' => 'true',
        'show_on' => 'both'

Date picker

Now my issue is language(locale is working fine). But when I am selecting the date instead of 31/March/2019 Its showing 31/03/2019 . Could you please tell what is the exact issue .

1 Answer 1


Its a default Magento bug :


To fix this issue you need to update the file :


Change line 46 as below

from :

$dateTime = $this->_localeDate->date($value, null, false);

To :

$dateTime = $this->_localeDate->date($value, null, false, false);
  • still same issue. Still coming as 20/03/2019
    – Gen Impact
    Mar 12, 2019 at 15:13

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.