“Date HTML” Réponses codées

entrée du calendrier

<input type="date" data-date-inline-picker="true" />
Thoughtless Teira

Date HTML

<label for="meeting">Next meeting (August 2021):</label>
<input type="date" 
       id="meeting" 
       name="meeting"
       min="2021-08-01" 
       max="2021-08-31"
       defaultValue="2021-08-01">
VasteMonde

Entrée de date HTML

<label for="start">Start date:</label>

<input type="date" id="start" name="trip-start"
       value="2018-07-22"
       min="2018-01-01" max="2018-12-31">
Karamolegkos

Date d'affichage sur HTML

<script>
  function startDate() {
    var d = new Date();
    var days = ["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"];
    var months = ["January","February","March","April","May","June","July","August","September","October","November","December"];
    document.getElementById("date").innerHTML = days[d.getDay()]+" | "+d.getDate()+" "+months[d.getMonth()]+" "+d.getFullYear();
  }
startDate();
</script>

<body onload='startDate()'>
  <div id='date'></div> <!-- use some css on #Date -->
</body>
hacknasawithmatlab

Réponses similaires à “Date HTML”

Questions similaires à “Date HTML”

Plus de réponses similaires à “Date HTML” dans HTML

Parcourir les réponses de code populaires par langue

Parcourir d'autres langages de code