0

Is there a way to force the HTML 5 date field to display other than the default text (placeholder text) This html 5 field <input type="date" name="datetest" /> display the control in browser like

enter image description here

can we change it to display like "mm/dd/yyy" ?

Sharath
  • 171
  • 1
  • 4
  • 18

1 Answers1

0

In addition to the comment options, there is a library, for masks input,if you are ready to use bootstrap, see the link: here

 $('input.date-picker').datepicker({
        format: "mm/dd/yyyy",
    });

Or if you prefer to use jquery only : here

$('input.date-picker').datepicker({ dateFormat: 'mm/dd/yyyy' });
Jerfeson Guerreiro
  • 745
  • 1
  • 10
  • 19