Hi
I'm not too sure how people DEBUG javascript
But I have found this very handy but I am sure your
mileage may vary.
It removes the need for using the 'alerts' left, right and everywhere
The only drawback is before a refresh of the Calling page,
you have to close this window also
(maybe set an onReload .. (close DEBUG window)
Anyways call it as such
var DEBUG = 1
...
if (DEBUG) doDEBUG('layer1 has loaded')
----------------------------------
function doDEBUG (str) {
if(!window.DEBUGWindow) {
window.DEBUGWindow = window.open("", "DEBUG", "width=300,
height=400");
// force the setting of the new windows parent
if(!window.DEBUGWindow.opener) window.DEBUGWindow.opener =
self
window.DEBUGDynDoc = new DynDocument(window.DEBUGWindow)
window.DEBUGDynDoc.setBgColor('#fff6f6')
window.debugIT = new DynLayer()
window.DEBUGDynDoc.addChild(window.debugIT)
}
window.debugIT.setHTML(window.debugIT.getHTML() + str + '<br>')
window.debugIT.setSize(300,window.debugIT.getContentHeight())
}
----------------------------------
------------------------------------------------
Ramon Buckland
Applications Engineer
email: [EMAIL PROTECTED]
web: www.f5.com.au
phone: (07) 3257 7900
fax: (07) 3257 7955
f5. Make the Medium Work. Simple.
------------------------------------------------
_______________________________________________
Dynapi-Dev mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/dynapi-dev