Debugging ADPs with TclPro

From AOLserver Wiki
Revision as of 09:08, 7 September 2006 by Bernhard (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Debugging AOLserver pages

Configure AOLserver to allow debugging, and restart:

   ns_section "ns/server/server1/adp"
       ns_param enabledebug true

Download and install the TclDevKit http://www.activestate.com

Start the debugger:

   % tcldebugger &

Start a new session:

   File > New-Project

Start a new remote session:

   Debugging Type > Remote Debugging

Append the following information to the page you wish to debug:

?debug=<debug>&dhost=<dhost>&dport=<dport>&dprocs=<dprocs>

AOLserver Dubugging Query Arguments:

 debug       String. The files you wish to debug. (Example: *, *.adp, foo.inc)
 dhost       String. The host name the Tcl debugger is listening on. (Example: 127.0.0.1)
 dport       Integer. The port the Tcl debugger is listening on. (Example: 2576)
 dprocs      String. Procedures to instrument. (Example: ns*, foo_something)

Example:

   http://foo.com:8000/test.adp?debug=*&dhost=127.0.0.1&dport=2576