Archive for May, 2006


Free Tools for Debugging Javascript (and Ajax apps) with Internet Explorer

Friday, May 26th, 2006

I have seen a lot of griping over the years about an imagined scarcity of debugging tools for IE. I find it remarkable that people in the business don’t know what’s available.

Microsoft has had great debugging tools for IE since Visual Interdev as far back as 1998 or so and continuing through to Visual Studio. The visual studio debugger has breakpoints, watch variables, call stack, step in/out/over, object browsing, immediate window, debug output window, and more.

If you didn’t want or need an entire IDE, Microsoft Script Debugger became available as a download for NT4 and Win98/ME, later becoming a component delivered with Windows operating systems as of Windows 2000 that simply required enabling. The Script Debugger is a lot lighter than the VS debugger, but still has breakpoints, watch variables, call stack, step in/out/over, immediate window, and debug output window.

Now Microsoft has released their Visual Web Developer Express IDE for free. Install it, then in your browser’s advanced options, uncheck the two boxes that disable debugging, and you have a debugger that is every bit as powerful as Mozilla’s Venkman ever was.

Here is a screenshot of a simple single-page debug session (click to open full size):

Visual Web Developer Debug Session

No wonder it took so long for Javascript to get any respect if people didn’t know that there were decent tools for it.


Today Creative Commons Salon, Tomorrow Mush

Tuesday, May 16th, 2006

I went along to the first Toronto Creative Commons Salon tonight and met some amazing folks. While I’m only on the periphery of this stuff, I had some great conversations and was able to act as a connector between some people and others with similar interests.

On the way back to the car, I managed to run into a whole gaggle of folks in post-Mesh celebration. I tell ya, this town she is a-hoppin’ with tech vibes.

Tomorrow night it’s off to Mush, the Web 2.0 Piss-Up. Hope to see you all there.

NOTE: I’ve been under the misapprehension that the Monarch Tavern, where Mush is being held, was all the way up at Bloor Street, however it turns out it’s down below College West of Bathurst as shown here


Ajax Experience – a play within a play

Monday, May 15th, 2006

There were two levels of conference going on at The Ajax Experience last week.

The first level was the conference where the presenters put on a terrific show for the attendees, with lots and lots of presentations about tools and techniques and a number of expert discussion panels.

The second level was the conference among the presenters, tool providers and industry experts, making the connections that will sow the seeds that make the coming years as exciting and fruitful as those recently gone by.

I was very happy to meet Douglas Crockford again. His work on JSONRequest and Javascript advocacy have been instrumental in sparking the conversations that will lead us towards changes in the browsers that will take us to the next level of not only interactive but even robust web applications. I applaud Douglas for taking a stand and proposing change. It comes as no surprise that Douglas is at Yahoo with Bill Scott, another guy at the absolute top of his game as an interaction designer. I’m noticing lately that Yahoo is quietly attracting the creme de la creme to work with them on advancing the state of the art in various ways while the other big guys are busy chasing the ball around.

In the browser camps, Brendan Eich shared his directions for Javascript and Mozilla, and Laurel Reitman helped us to understand that the IE7 team is keen to help us all move forward and solve the challenges that are decelerating our efforts – cross-domain security for instance. While there was some contention, the overall impression was of cautious steps towards increased levels of openness and collaboration.

Michael Mahemoff impressed me as someone who is truly passionate about patterns. His work in gathering patterns from far and wide has no doubt helped us all tremendously.

Big thanks to Dion Almaer and Ben Galbraith, who had the foresight to gather together a remarkable mix of thought leaders and catalysts to make a lasting difference, and who along with Jay Zimmerman did a stellar job of hosting what to many in attendance will be remembered as the tech event of the year.


Ajax Experience

Thursday, May 11th, 2006

I’m in San Francisco at The Ajax Experience. Alex Russell is explaining the Dojo Toolkit, one of the primo Ajax toolkits. I’m seated beside Douglas Crockford and directly behind Michael Mahemoff of Ajax Patterns.

Last night I sat on an expert panel, after which a few people gathered by the podium to speak. Laurel Reitman, Lead Program Manager for IE7 came over to get involved in the conversation, and I took the opportunity to introduce her to Brendan Eich, CTO of Mozilla. It certainly looks like this conference could be a catalyst in some really great forward movement.


IE7 XMLHttp resending requests?

Friday, May 5th, 2006

Tucows used BlogChat earlier this week for the Ask Tucows chat they regularly host for their partners, clients and other interested parties.

After the chat was closed, I noticed that Bryan’s browser continued to resend chat messages. These were repeats of earlier conversation from his browser, and being sent in their original order, although not with exactly the same timed spacing. They were actually coming in as logged http requests from his IP. I quickly got Bryan’s number from whois and called him at his desk. He still had the browser running, but had closed the chat tab immediately after the chat. His browser continued to send these old messages after the tab was closed!

I’ve looked at our code. We recently changed the transport method on the visitor chat client from img/cookie to XMLHttp (with failover to hidden Iframe) to a) avoid cross-domain problems in embedded chat windows and b) be more AJAXY. The code creates a new XMLHttp object each time but then does not explicitly dispose of it once its onLoad has fired. The polling nature of the app means that many of these objects are being created. I’ve yet to
determine whether certain browsers keep them around where others don’t.

My working theory is that IE7’s native browser implementation of XMLHttp (as opposed to IE6’s ActiveX implementation) not only keeps these objects around, but for some reason starts re-firing them later on, for some reason in the order that they were created.

While I’ll definitely look into disposing of the objects once used, I think this behaviour could constitute a pretty nasty bug if your ajax calls do things like “delete record” or “apply charge to account”.

I’m away at The Ajax Experience next week but after that I’ll set up a vm test environment. In the meantime, has anyone had similar experiences with IE7 and XMLHttp?