Stefan Says

Opinions on ASP.NET, ASP, databases etc
posts - 34, comments - 25, trackbacks - 23

Ajax for ASP.NET or something else

As you might have read in my earlier blog posts (and on my site as well) I have had a hard time deciding which road to take when it comes to Ajax enabling my ASP.NET apps. Atlas felt so bloated back this autumn  - and since it was not even released (other than in betas) I decided to check out the market. I really liked (and still like) JQuery. One example really showing you how to use JQuery in ASP.NET scenarios is JQuery and ASP.NET - lets involve ASP.NET

I think JQuery is pretty brilliant and darn elegant - and I did use JQuery for my findfreefonts.net project. For such a project I found JQuery to be outstanding. Making unobtrousive javascripts (meaning not tied to or "destroying" the actual html tags), and I was able implement some really cool client side stuff, such as storing your favorite fonts in cookie meaning you never have to login etc. Also the backend part went fine - I have implemented ajax paging and the greatest part of it all was that I could do that in an unobtrousive  way as well - meaning I have a javascript (just a few rows of code - that's jquery in a nutshell) to change the regular thesite.com/show.aspx?page=12 or whatever into a Ajax call. Meaning if the visitor (even automatic ones, like an search engine bot) didn't have javascript enabled it would indeed show the regular link.

That's on the plus side for JQuery. What I have found harder - is some areas of server side integration. For example forms validation. The validator controls in ASP.NET 2.0 are really nice - especially in the sense that they are always executed on  the server side as well. For more regular apps (forms based so to speak) I think you get some extra job when using JQuery -  naturally  since JQuery is indeed totally client side. As compared to a regular ASP.NET solution that is. Heck, I mean I even strived to remove the viewstate altogether at findfreefonts.net so that was really a client side solution!

So, I have now started looking at Ajax for ASP.NET , formally Atlas, cause it's finally been publicly released . I installed it - and the controls toolkit, yesterday and to my surprise I was able to create a working live.com image search like solution in just a few hours (be sure to start at part 1 - I'm linking you to the last page so you can see the result).

What I don't like so far is that external Javascript statements are sprinkled all over my code - and still some issues to work on when it comes to master pages - but all in all - I am actually impressed. I will keep you updated on this matter - cause there are a lot of things for me to figure out before I feel I have the necessery control /that's me in a nutshell) to use it in real world scenarios.      

Print | posted on Tuesday, January 30, 2007 9:38 AM