MagicAjax - Easy as 1, 2, 3

written by Ryan Olshan on Tuesday, December 20 2005

A couple of days ago I discovered MagicAjax. MagicAjax simplifies creating Ajax enriched content. So, how do you use MagicAjax?

Click here to download MagicAjax.

Step 1 Add a reference to the MagicAjax assembly to your project or a copy of it to the bin directory if you are not using an IDE. Also, add the following HTTP module reference to Web.config:

<system.web>
   <httpModules>
      <add name="MagicAjax" type="MagicAjax.MagicAjaxModule, MagicAjax" />
   </httpModules>
</system.web>

Step 2 Add the following to top of the web form you would like to use MagicAjax on:

<%@ Register TagPrefix="ajax" Namespace="MagicAjax.UI.Controls" Assembly="MagicAjax" %>

Step 3 Use the AjaxPanel control as a place holder for content that you would like to enable Ajax on.

<ajax:AjaxPanel ID="AjaxPanel1" runat="server">
   [Content here]
</ajax:AjaxPanel>

There you have it. It's as easy as 1, 2, 3.

Kick this post on .NET Kicks

Similar Posts

  1. Dev Connections Day 2
  2. Redirecting Community Server Blogs
  3. Running different versions of the same assembly

Comments

  • Leonardo on on 1.03.2006 at 12:53 PM

    Leonardo avatar

    it's amazing !

  • Ekrmweb on on 1.06.2006 at 10:58 AM

    Ekrmweb avatar

    Thanks , It's what I've been looking for exactly!

  • Cliff Spence on on 1.24.2006 at 8:58 PM

    Cliff Spence avatar

    This is incredible, man, seriously. Thanks!



    One question, though, is there any way I can get the output to validate as XHTML? The option to use the ID attribute instead of the Name attribute, getting rid of the '$' character in the IDs, not wrapping everything within span tags, no proprietary attributes rendered, 'type' attribute used in script tags, etc.?

  • Ryan Olshan on on 1.25.2006 at 10:49 AM

    Ryan Olshan avatar

    I think the XHTML thing is something that will be available in the next release. The only way to change that behavior would be to modify the code, but I'd ask that question to the MagicAjax forums http://forum.magicajax.net.



    Ryan

Post a comment