Using Microsoft's CDN Service with jQuery

Microsoft yesterday announced it has created a new Microsoft Ajax CDN (Content Delivery Network) that provides caching support for Ajax libraries. The CDN contains copies of data, placed at various locations, to maximize bandwidth. For example if your website is hosted in Australia, but you’re a visitor from the United Kingdom, then the data must travel between those two points. A CDN allows the visitor in the UK to download the files near themselves as opposed to the server in Australia. This provides a real boost to a websites performance.

You can get a full listing of the JavaScript libraries (and associated URLs) we already have loaded in our CDN cache here. To use this with jQuery, simply add the full path to the CDN service:

If you copy the example above and run it locally, you’ll be using a copy of jQuery’s library that is closest to your current location.

Will you give this article a +1 ? Thanks in advance

About The Author

Malcolm Sheridan is a Microsoft awarded MVP in ASP.NET and regular presenter at conferences and user groups throughout Australia. Being an ASP.NET Insider, his focus is on web technologies and has been for the past 10 years. He loves working with ASP.NET MVC these days and also loves getting his hands dirty with JavaScript. He also blogs regularly at DotNetCurry.com. Follow him on twitter @malcolmsheridan