topical media & game development

talk show tell print

basic-javascript-04-ch04-q1.htm / htm



  <html>
  <body>
  <script language="JavaScript" type="text/javascript">
  
  var months = new Array("Jan","Feb","Mar","Apr","May","Jun","Jul","Aug",
                             "Sep","Oct","Nov","Dec");
  var nowDate = new Date();
  
  nowDate.setMonth(nowDate.getMonth() + 12);
  document.write("Date 12 months ahead is " + nowDate.getDate());
  document.write(" " + months[nowDate.getMonth()]);
  document.write(" " + nowDate.getFullYear());
  
  </script>
  </body>
  </html>
  


(C) Æliens 20/2/2008

You may not copy or print any of this material without explicit permission of the author or the publisher. In case of other copyright issues, contact the author.