Welcome to JavaScript Finder
Javascript Date & Time
The Format for the Time & Date is setup like this.
getSeconds() - Number of seconds (0-59)
getMinutes() - Number of minutes (0-59)
getHours() - Number of hours (0-23)
getDay() - Day of the week(0-6). 0 = Sunday : 6 = Saturday
getDate() - Day of the month (0-31)
getMonth() - Number of month (0-11)
getFullYear() - The four digit year
JavaScript : Date
<script language="JavaScript">
<!--
var currentDate = new Date()
var month = currentDate.getMonth() + 1
var day = currentDate.getDate()
var year = currentDate.getFullYear()
document.write("<b>" + month + "/" + day + "/" + year + "</b>")
-->
</script>
It Displays :
Now we can show the time like this.
JavaScript : Time
<script language="JavaScript">
<!--
var d = new Date()
document.write(d.getHours())
document.write(".")
document.write(d.getMinutes() + 1)
document.write(".")
document.write(d.getSeconds())
-->
</script>
It Displays :