Main Page

Venkman – Mozilla’s debugger

Venkman – Mozilla’s debugger
The Mozilla debugger, Venkman (named after the character Peter Venkman of the
is a free utility for Mozilla-based browsers (including Firefox). To install, open up your Mozilla browser
and go to
. At this address, you find a list of all the
Venkman builds. Click the Install link next to the latest version. You are prompted to continue the instal-
lation because Venkman is an unsigned Mozilla plugin. Click Install Now. Restart the browser and you
notice a new entry under the Tools
Web Development menu.
To run Venkman, click Tools
Web Development
JavaScript Debugger to manually open the win-
dow. When you do so, the Venkman window automatically loads all the files containing JavaScript into
the debugger.
You can also use the
command in your code. It works with Microsoft’s Script Debugger. Any
time you include the
command, the debugger opens up at that line of code and stops execution.
Unlike Internet Explorer, Mozilla never asks you if you’d like to debug an error.
The Window
The Venkman window (Figure 14-14) is much more complicated than the Microsoft Script Debugger, but
also a lot more powerful.
The window is made up of several smaller windows (or views) containing various information about
the scripts you are inspecting. Each view is made up of several common components, as illustrated in
Figure 14-15.
The Microsoft Script Debugger is, ironically enough, buggy. On machines using
Windows 2000 and later, the Script Debugger seems to have problems staying acti-
vated. It’s not uncommon to use the debugger during one Windows session, shut
down the computer, and return only to find that the menu items in Internet Explorer
have disappeared. If this happens, go into Internet Options and click on the
Advanced Tab. Select the check box labeled Disable Script Debugging and click the
Apply button. Then, uncheck the check box and click the OK button. Most of the
time, this re-enables the debugger.
Error Handling
17_579088 ch14.qxd 3/28/05 11:41 AM Page 435

JavaScript EditorFree JavaScript Editor     Ajax Editor