JavaScript System Date - Does not appear on screen

May 08, 2014

I don't know much about JavaScript (I have enrolled in a course that begins next week) so please bear with me and, if you can, translate your replies into "Captain Dummy-Speak" for me.  Assume I know nothing, because at this point, it's accurate.

I am trying to pull the system date from the computer to display on another page. I have created a text variable SystemDate and have copy & pasted the following JavaScript

var currentTime = new Date();

var monthArray = new Array  ("January","February","March","April","May","June","July","August","September","October","November","December");

 var month = currentTime.getMonth();

 var theMonth = monthArray[month];

 var day = currentTime.getDate();

 var year = currentTime.getFullYear();

 var dateString= day + " " + theMonth + " " + year;

 var player = GetPlayer();


The JavaScript is set to trigger when timeline starts on the slide.  

When I publish and view the course (from harddrive) in my browser, the %SystemDate% area of the textbox is blank.  All my other variables (user entered) appear on the page correctly.

I am using Update 5: 1401.2415 and viewing the output in IE 11.   

Does anyone have any ideas as to why the field is displaying no information?

2 Replies

This discussion is closed. You can start a new discussion or contact Articulate Support.