Jul
18
2009
How to Add the Current Date to your webpage with Javascipt

The other day I was cutting and coding a website for a bank. One feature that was in the header was the current date, which would update daily (duh). I know in a previous project I had done this with Javascipt, so I back-tracked and got the code I used before. Here is the code, which will print the date on your web page in the following format:
July 18, 2009
The first step is to link your XHTML page to the external Javascript page, which has the code which will make it all happen. Paste the code below in the Head of your page.
Link to external Javascript File
<script type="text/javascript" src="js/date.js"></script>


Recent Comments