13
Debugging Scripts
This chapter describes the JavaScript debugging tools that the SDK provides, and discusses techniques for
JavaScript debugging.
You must enable debugging services to use the debugging tools. See
●
The JavaScript Debugger provides a command line and output view you can use to execute JavaScript
●
code interactively in the scope of a particular module. See
The Internal JavaScript Source Debugger
●
breakpoints listing, step tracing, an interactive JavaScript command line, and the ability to edit live
JavaScript objects from within breakpoints.
GoLive uses the internal JavaScript Debugger by default. You can set it to use the Adobe ExtendScript
Toolkit instead, by setting the property settings.sdk.internalDebugger=false . The Toolkit is
described in
Enabling Debug Services
By default, all debugging services are disabled. If no module enables the debugger, the JavaScript
Debugger window is not available.
Debugging services are enabled when at least one extension module adds the debug attribute to the
<jsxmodule> tag or when at least one currently loaded script contains the debugger statement.
If the JavaScript Debugger window was open when the last user session with GoLive ended, the window
opens automatically next time GoLive starts. In this case the window can be open but not responsive to
input (if no modules currently enable debugging services).
Note:
To enable debugging services quickly and easily, drag any of the sample extensions supplied by the
SDK into your GoLive 7.0_Lang/Modules/Extend Scripts folder and restart GoLive. The
sample all enable debugging.
The debug attribute in a particular <jsxmodule> tag activates the internal debugger for its own module
only. However, once any module activates the internal debugger, the JavaScript Debugger window
becomes available to all extensions, even those that do not specify the debug attribute.
Chapter 5, "ExtendScript Tools and
Using the JavaScript Command
is a fully featured debugger that provides a detailed
Features, " of the GoLive CS2 SDK Programmer's Reference.
Enabling Debug Services
Shell.
170