Skip to main content
Participating Frequently
October 19, 2009
Question

dataFromFlash() and eval’ed JS in scorm_support.js

  • October 19, 2009
  • 1 reply
  • 633 views

While viewing a Presenter presentation online, I had Firebug open and noticed a JavaScript error that I think might be caused by the Presenter Flash object. An example of the error I saw:

unterminated string literal

This happened after I typed "hey<newline>you" into a free-form quiz field and went to the next slide.

From what I can tell, the Flash object is internally building up a string to call dataFromFlash() (in the scorm_support.js file) and running that string in the JavaScript context. According to Firebug, the command it invoked was this:

My guess is that the %0D in the command was evaluated and turned into ASCII 13 (newline) and that resulted in a JavaScript line that was not properly terminated. (If my free-form text field doesn't contain any newlines, there is no error.)

Anybody know what's going on? Any fix, or is this a bug that Adobe knows about?

This topic has been closed for replies.

1 reply

Jase415Author
Participating Frequently
October 19, 2009

P.S. There is also a JS error if the free-form survey response contains quote characters. :-(