Sunday, May 14, 2006
Ope on Atlas 04-26-2006
Awrite here’s the intro…
ope@splasherstech.com>
PREAMBLE
Traditionally, if your web page contains links with which you activate some code on the server side, you page has to post back when that link is clicked so that the code can run and send updated HTML for the response page for the browser to display. This could be pretty annoying if you have a lot of little buttons everywhere on the page that don’t do much other than update a little part of the page. This is where AJAX comes in.
AJAX
AJAX stands for Asynchronous Javascript And XML. Lets leave the big English and say exactly what it is.
Point of History: The XMLHTTPObject was introduced into IE some times back (I don’t know what version J). With the XMLHTTPObject you can make the browser initiate an asynchronous request to the Server under the hood and obtain a stream of HTML as response which with some funky Javascript you can now insert in specific areas of the page. As far as the user is concerned the page did not post back. The XMLHTTPObject (or its variants) has since been included in other browsers.
So that’s what AJAX is. Most common examples are Gmail, MSN Maps, etc.
AJAX Frameworks
Most of us average web programmers are lousy client side programmers (J). All we want is our code on the server side to do what we want it to do. Knowing this, a number of people therefore try to provide some sort of framework for web developers to take advantage of AJAX in their web apps without having to write a lotta the client side script to tie things together. These frameworks spit out just the right Javascript you need to place your asynchronous requests on the client side and parse the results for placement in specific portions of the existing page. This way web developers can concentrate on writing their web apps the way they are used to and just follow their framework’s “how to” to AJAX enable their apps.
DotNet and AJAX.
For ASP.Net developers there are a number of AJAX frameworks to use to write AJAX enabled web apps. They follow different approaches to achieve the common goal. Some include AJAX.Net, MagicAjax, etc. Microsoft’s own implementation is codenamed “Atlas”. Currently under some sort of proof of concept development by the ASP.Net core team. The Alpha is not even out. What we have are just geek previews. The latest version I think is the March CTP.
How Atlas works
Atlas follows the simple approach in which you add a reference to the Atlas assembly to your application and you get a client script generator called a ScriptManager to handle your client side scripting which u can put on your page. This script manager handles the client side scripting together with the help of a number of other web controls (primary among them is the UpdatePanel) to take care of all the buhaha you need to make Ajax work for you.
Any portion of you page that you want to AJAX enable, all you have to do is place an updatePanel around it. And Voila it works! Well, not just like that, there’s a few things you need to do. But it’s all more declarative than code writing.
That’s basically how it works.
Scott Guthrie of the ASP.Net posted a “from scratch” video last week that shows an ASP.Net 2.0 site created and later AjAX enabled. I’ll try to reproduce what he did in that video in our next geekify session, to give us an appetite wetter so we can go off and try stuff on our own.
See ya there!
NB:
You will need a few things before then.
VS 2005 installed on your box.
Atlas installed on your box (\\moses\Shared\TEMP\Setup\Atlas (March CTP)\ AtlasSetup_MarchCTP.msi)
You may want to watch the video b4 then too (\\moses\Shared\TEMP\Setup\Atlas (March CTP)\ atlas_Scott_Guthrie_Killer_demo.wmv)
Buchao!!!(TM)
ope@splasherstech.com>
PREAMBLE
Traditionally, if your web page contains links with which you activate some code on the server side, you page has to post back when that link is clicked so that the code can run and send updated HTML for the response page for the browser to display. This could be pretty annoying if you have a lot of little buttons everywhere on the page that don’t do much other than update a little part of the page. This is where AJAX comes in.
AJAX
AJAX stands for Asynchronous Javascript And XML. Lets leave the big English and say exactly what it is.
Point of History: The XMLHTTPObject was introduced into IE some times back (I don’t know what version J). With the XMLHTTPObject you can make the browser initiate an asynchronous request to the Server under the hood and obtain a stream of HTML as response which with some funky Javascript you can now insert in specific areas of the page. As far as the user is concerned the page did not post back. The XMLHTTPObject (or its variants) has since been included in other browsers.
So that’s what AJAX is. Most common examples are Gmail, MSN Maps, etc.
AJAX Frameworks
Most of us average web programmers are lousy client side programmers (J). All we want is our code on the server side to do what we want it to do. Knowing this, a number of people therefore try to provide some sort of framework for web developers to take advantage of AJAX in their web apps without having to write a lotta the client side script to tie things together. These frameworks spit out just the right Javascript you need to place your asynchronous requests on the client side and parse the results for placement in specific portions of the existing page. This way web developers can concentrate on writing their web apps the way they are used to and just follow their framework’s “how to” to AJAX enable their apps.
DotNet and AJAX.
For ASP.Net developers there are a number of AJAX frameworks to use to write AJAX enabled web apps. They follow different approaches to achieve the common goal. Some include AJAX.Net, MagicAjax, etc. Microsoft’s own implementation is codenamed “Atlas”. Currently under some sort of proof of concept development by the ASP.Net core team. The Alpha is not even out. What we have are just geek previews. The latest version I think is the March CTP.
How Atlas works
Atlas follows the simple approach in which you add a reference to the Atlas assembly to your application and you get a client script generator called a ScriptManager to handle your client side scripting which u can put on your page. This script manager handles the client side scripting together with the help of a number of other web controls (primary among them is the UpdatePanel) to take care of all the buhaha you need to make Ajax work for you.
Any portion of you page that you want to AJAX enable, all you have to do is place an updatePanel around it. And Voila it works! Well, not just like that, there’s a few things you need to do. But it’s all more declarative than code writing.
That’s basically how it works.
Scott Guthrie of the ASP.Net posted a “from scratch” video last week that shows an ASP.Net 2.0 site created and later AjAX enabled. I’ll try to reproduce what he did in that video in our next geekify session, to give us an appetite wetter so we can go off and try stuff on our own.
See ya there!
NB:
You will need a few things before then.
VS 2005 installed on your box.
Atlas installed on your box (\\moses\Shared\TEMP\Setup\Atlas (March CTP)\ AtlasSetup_MarchCTP.msi)
You may want to watch the video b4 then too (\\moses\Shared\TEMP\Setup\Atlas (March CTP)\ atlas_Scott_Guthrie_Killer_demo.wmv)
Buchao!!!(TM)