HTML5 generates a data picker using:
<input type="date">
On my browser at least, the week starts on Monday. Is there a way of starting the week on Sunday (or any other particular day)?
HTML5 generates a data picker using:
<input type="date">
On my browser at least, the week starts on Monday. Is there a way of starting the week on Sunday (or any other particular day)?
It's quite a lazy solution, I know, but Jquery does the job quite well.
$("document").ready(function () {
$( "#datepicker" ).datepicker({defaultDate: null, firstDay: 1});
})
<script src="https://code.jquery.com/jquery-3.6.0.js"></script>
<link rel="stylesheet" href="https://ajax.googleapis.com/ajax/libs/jqueryui/1.12.1/themes/smoothness/jquery-ui.css">
<script src="https://ajax.googleapis.com/ajax/libs/jqueryui/1.12.1/jquery-ui.min.js"></script>
<input type="text" id="datepicker">
If you want higher security then you can download version 1.13 of jQuery UI on your PC, as 1.12 has some vulnerabities and Google doesn't host the newest version yet.
I think you cant but maybe you can use Javascript for change the First day but i dont know you can try use Javascript but i think you cant change it maybe you can change only on Local maybe.
Unfortunately, that is not something you can do, this feature was not taken into consideration when this element in the markup of HTML was designed.
May be by using a custom date picker library like datepicker.js, you can have more control over the behaviour of the date picker, including setting the starting day of the week.
Hope this helps.