Contents tagged with Microsoft AJAX Library
-
Is Safari on Windows a good thing or a bad thing?
The first thing most web developers probably thought this morning when they learned about Safari for Windows was "oh man, yet another browser to test in". And yes, for the moment, that's what it amounts to. Coincidentally, I have spent a good part of last week making the history management in Microsoft Ajax work in Safari 2.0.4. I got it to work fine (after much Apple cursing), so the first thing I tried after I downloaded Safari 3 beta was my history tests. And sure enough, it breaks in new, unexpected ways. History management is pretty much a big hack that is different on about all browsers (Firefox and Opera are the nicest ones here, with predictible, similar behaviors). And sure enough, Safari 3 brings a totally unheard of model. I didn't find a way yet to create a new entry in history from script that doesn't navigate away from the page. None of the old Safari tricks work anymore (they were probably and rightfully considered bugs and were fixed). They weren't replaced by the more rational things that work in Firefox and Opera. Even the iFrame trick that we use on IE doesn't work because Safari now crashes if you try to dynamically add a frame to the DOM. If anybody here found a way to do that, I'd love to hear about it.
-
Microsoft Ajax events - part 2: exposing events from custom classes
-
Microsoft Ajax events - part 1: subscribing
When building Ajax applications, you basically deal with two kinds of events. First, there are DOM events, and second, events from JavaScript objects. This second category is not part of the EcmaScript specs (or of the DOM specs, of course) so each framework needs to define its own pattern to expose events. This makes it more difficult for developers to include components built on different frameworks into a single page, which is one of the problems that OpenAjax tries to solve. I'll get back to this in a future post and show how to integrate Microsoft Ajax events in the OpenAjax hub.
-
Woohoo! I'm on TV!
The latest episode of the .NET show is all about ASP.NET Ajax. Brad and Matt first have a really interesting discussion of the history and architecture of ASP.NET Ajax and then you can see me demo-ing UpdatePanel, extenders and localization.
-
The format for JavaScript doc comments
Xml documentation annotations are going to drive JavaScript IntelliSense in Visual Studio Orcas (the next version of Visual Studio). For more than a year now, we've been including xml doc comments to all public APIs in the Microsoft Ajax Library (which are a great place to check out some examples of those comments). We also use the doc comments to automatically generate parameter validation code in the debug version of our scripts.
-
How to keep some context attached to a JavaScript event handler?
The problem is the following... You want to attach a handler to a DOM event but you want some information to remain associated with it. Let's say for example that the handler is a method of an object that makes use of the "this" pointer somewhere in its body (as it should, otherwise it should probably be static). As the API to attach a handler just takes a function pointer, and the "this" pointer is determined by the DOM element that triggered the event, it seems difficult to do. The Microsoft Ajax Library (like almost all Ajax libraries, let's be honest) provides an easy way to work around that. If you call:
-
OpenAjax meetings
It was my great pleasure to be at the face to face OpenAjax Alliance meetings for the first time last month. Thanks to the nice people at IBM for hosting them. I really enjoyed the discussions with Alex from Dojo, Gideon from OpenSpot and many others. There were also great demos of OpenAjax-based interoperability.
-
Scott on JSON hijacking
Scott has a great post on how ASP.NET Ajax has built-in mitigations already in place for JSON hijacking attacks:
http://weblogs.asp.net/scottgu/archive/2007/04/04/json-hijacking-and-how-asp-net-ajax-1-0-mitigates-these-attacks.aspx -
ASP.NET Ajax UpdatePanel PDF erratum
I corrected a few remaining errors in our O'Reilly shortcut on UpdatePanel (mainly references to the old Atlas codename). If you already bought it, you can download the new version for free. And if you haven't, what are you waiting for? ;)
-
Microsoft joins OpenAjax
I'm extremely pleased to announce that we're joining OpenAjax today and that I'll represent the company in the organization's meetings starting this Thursday. This is a way for us to ensure that our user community can combine the Microsoft AJAX Library and ASP.NET 2.0 AJAX Extensions with other frameworks, today and in the future. Interoperability in the browser is a hard problem but it opens key Ajax scenarios. An industry-wide organization such as OpenAjax is a great way to ensure this goal is met in the long-term.