May 7, 2013

Finding weekday of a particular date

Coding

<html>
<body>
<script language="JavaScript">
var d=new Date()
var weekday=new Array("Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday")
document.write("Today is " + weekday[d.getDay()])
</script>
</body>
</html>

No comments:

Post a Comment

Popular Posts

Views