I\'m working with HTML5 elements on my webpage. By default input type=\"date\"
shows date as YYYY-MM-DD
.
The question is, is it possible t
Browsers obtain the date-input format from user's system date format.
(Tested in supported browsers, Chrome, Edge.)
As there is no standard defined by specs as of now to change the style of date control, its not possible to implement the same in browsers.
However, This behavior of obtaining the date format from system settings is better and I strongly suggest, we should not try to override it. The reason is, the users will see the date-input's format same as they have configured in the system/device and which they are comfortable with or matches with their locale.
Remember, this is just the UI format on the screen which users see, in your javascript/backend you can always keep your desired format.
Refer google developers page on same.