-1

This is how it should look on all the browsers: enter image description here

And this is how it looks on Safari, for example: enter image description here

This is the code that I am using at the moment:

<%= date_field 'birth_date', rel => 'birth_date',
        class => "form-control", required => undef %>
ikegami
  • 367,544
  • 15
  • 269
  • 518
Marinescu
  • 429
  • 3
  • 18
  • A date picker can be useful for selecting dates within a month or two of "today", but is seldom a good match for a Date of Birth field. I created the [jQuery date text entry](http://grantm.github.io/jquery-datetextentry/) plugin for this type of field. – Grant McLean Oct 05 '20 at 21:23

1 Answers1

1

You're using the Mojolicious date_field tag helper. This generates a <input type="date"> HTML input field.

But support for the date input isn't universal. In particular, you'll see that Safari doesn't support it.

So you'll need to use some kind of plugin, I guess. If you're using jQuery, then one of these might work for you.

Dave Cross
  • 68,119
  • 3
  • 51
  • 97