<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>FerretArmy: A Web Developer&#039;s Paradise &#187; ASP.NET Ajax</title>
	<atom:link href="http://www.ferretarmy.com/tag/aspnet-ajax/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.ferretarmy.com</link>
	<description>Pushing the Web Forward, Since 2007</description>
	<lastBuildDate>Wed, 18 Jan 2012 15:58:58 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>jQuery Ajax Beats ASP.NET Ajax</title>
		<link>http://www.ferretarmy.com/2009/06/04/jquery-ajax-beats-aspnet-ajax/</link>
		<comments>http://www.ferretarmy.com/2009/06/04/jquery-ajax-beats-aspnet-ajax/#comments</comments>
		<pubDate>Thu, 04 Jun 2009 17:50:32 +0000</pubDate>
		<dc:creator>Jon</dc:creator>
				<category><![CDATA[.NET]]></category>
		<category><![CDATA[Ajax]]></category>
		<category><![CDATA[ASP.NET]]></category>
		<category><![CDATA[C#]]></category>
		<category><![CDATA[Geeky]]></category>
		<category><![CDATA[jQuery]]></category>
		<category><![CDATA[WebDev]]></category>
		<category><![CDATA[ASP.NET Ajax]]></category>

		<guid isPermaLink="false">http://www.ferretarmy.com/?p=338</guid>
		<description><![CDATA[ASP.NET Ajax is a good technology in theory, but the implementation in practice is anything but smooth. There are many little &#8216;quirks&#8217; that ASP.NET Ajax does to your page; these quirks almost entirely revolve around the handling of viewstate during ajax calls. ASP.NET Ajax passes the viewstate to the server and back during things like [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.asp.net/ajax/">ASP.NET Ajax</a> is a good technology in theory, but the implementation in practice is anything but smooth. There are many little &#8216;quirks&#8217; that ASP.NET Ajax does to your page; these quirks almost entirely revolve around the handling of <a href="http://msdn.microsoft.com/en-us/library/ms972976.aspx">viewstate</a> during ajax calls.</p>
<p>ASP.NET Ajax passes the viewstate to the server and back during things like <a href="http://msdn.microsoft.com/en-us/library/system.web.ui.updatepanel.aspx">UpdatePanel</a> updates. This is done to insure that the viewstate is always up to date, even if the page information changes during the Ajax call. Many Ajax calls, however, don&#8217;t require any changes to viewstate. Unfortunately, when the viewstate comes back, I&#8217;ve found many unpredictable results &#8211; things like page titles changing and breaks in back-button functionality in some scenarios. More importantly, these bugs are hard to track down and understand, in my experience. On top of this, viewstate is usually pretty large, which slows down ASP.NET Ajax requests and transfers more data across the wire, increasing bandwidth costs.</p>
<p>What have I chosen to do instead? Through <a href="http://encosia.com/2008/03/27/using-jquery-to-consume-aspnet-json-web-services/">Encosia</a>, I&#8217;ve found that it&#8217;s fairly trivial to make <a href="http://jquery.com/">jQuery</a> Ajax calls into the codebehind, or even to local web services via <a href="http://www.json.org/">JSON</a>. These calls are small (they don&#8217;t send viewstate), transparent (they don&#8217;t change page information on return unless you explicitly ask to), cross-browser compatible, and rock-solid (like everything in jQuery).</p>
<p>Surely there are quite a few circumstances where ASP.NET Ajax beats out jQuery Ajax (for things like datagrid population, for example). From now on, though, I&#8217;ve decided that my default stance will be to write my Ajax calls in jQuery unless I can create a compelling case to do so in another technology.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ferretarmy.com/2009/06/04/jquery-ajax-beats-aspnet-ajax/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

