<?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>The Tutorial Blog &#187; e-commerce</title>
	<atom:link href="http://www.thetutorialblog.com/tag/e-commerce/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.thetutorialblog.com</link>
	<description></description>
	<lastBuildDate>Wed, 07 Jul 2010 23:30:44 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0</generator>
<image>
<link>http://www.thetutorialblog.com</link>
<url>http://www.thetutorialblog.com/wp-content/plugins/maxblogpress-favicon/icons/favicon-28.ico</url>
<title>The Tutorial Blog</title>
</image>
		<item>
		<title>ASCIICasts: AJAX History and Bookmarks</title>
		<link>http://www.thetutorialblog.com/external/asciicasts-ajax-history-and-bookmarks/</link>
		<comments>http://www.thetutorialblog.com/external/asciicasts-ajax-history-and-bookmarks/#comments</comments>
		<pubDate>Sat, 12 Sep 2009 22:30:25 +0000</pubDate>
		<dc:creator>Wez Pyke</dc:creator>
				<category><![CDATA[External]]></category>
		<category><![CDATA[active-record]]></category>
		<category><![CDATA[active-support]]></category>
		<category><![CDATA[ajax]]></category>
		<category><![CDATA[authentication]]></category>
		<category><![CDATA[caching]]></category>
		<category><![CDATA[controllers]]></category>
		<category><![CDATA[debugging]]></category>
		<category><![CDATA[e-commerce]]></category>
		<category><![CDATA[forms]]></category>
		<category><![CDATA[models]]></category>
		<category><![CDATA[performance]]></category>
		<category><![CDATA[plugins]]></category>
		<category><![CDATA[rails-22]]></category>
		<category><![CDATA[rails-23]]></category>
		<category><![CDATA[refactoring]]></category>
		<category><![CDATA[routing]]></category>
		<category><![CDATA[ruby on rails]]></category>
		<category><![CDATA[security]]></category>
		<category><![CDATA[testing]]></category>
		<category><![CDATA[tools]]></category>
		<category><![CDATA[views]]></category>

		<guid isPermaLink="false">http://www.thetutorialblog.com/?p=133</guid>
		<description><![CDATA[	<style>
	#code_div { border: 1px solid #DFF4B5; background-color: #F0FFD2; padding-left: 50px; padding:10px;}
	</style>
	
		<style>
	#code_div { border: 1px solid #DFF4B5; background-color: #F0FFD2; padding-left: 50px; padding:10px;}
	</style>
	
		<style>
	#code_div { border: 1px solid #DFF4B5; background-color: #F0FFD2; padding-left: 50px; padding:10px;}
	</style>
	
		<style>
	#code_div { border: 1px solid #DFF4B5; background-color: #F0FFD2; padding-left: 50px; padding:10px;}
	</style>
	
		<style>
	#code_div { border: 1px solid #DFF4B5; background-color: #F0FFD2; padding-left: 50px; padding:10px;}
	</style>
	
		<style>
	#code_div { border: 1px solid #DFF4B5; background-color: #F0FFD2; padding-left: 50px; padding:10px;}
	</style>
	
		<style>
	#code_div { border: 1px solid #DFF4B5; background-color: #F0FFD2; padding-left: 50px; padding:10px;}
	</style>
	
	View full tutorial In the last episode we added AJAX functionality to a paginated list of products. Instead of acting as normal HTML links, the paginated links had click events added to them via unobtrusive JavaScript so that when clicked they made an AJAX request that updated the main content of the page with a [...]


Related posts:<ol><li><a href='http://www.thetutorialblog.com/jquery/deep-linking-with-jquery/' rel='bookmark' title='Permanent Link: Deep Linking with jQuery'>Deep Linking with jQuery</a> <small>You can view a demo and download the resources for...</small></li>
<li><a href='http://www.thetutorialblog.com/jquery/10-awesome-jquery-tutorials-you-should-check-out/' rel='bookmark' title='Permanent Link: 10 Awesome jQuery Tutorials You Should Check Out'>10 Awesome jQuery Tutorials You Should Check Out</a> <small>jQuery is a great tool that everyone in web development...</small></li>
<li><a href='http://www.thetutorialblog.com/text-tutorials/quick-tip-resolving-conflicting-problems-between-jquery-and-mootools-or-any-other-javascript-library/' rel='bookmark' title='Permanent Link: Quick Tip: Resolving conflicting problems between jQuery and MooTools or any other Javascript library'>Quick Tip: Resolving conflicting problems between jQuery and MooTools or any other Javascript library</a> <small>Recently I wrote quite a huge chunk of jQuery for...</small></li>
</ol>

Related posts brought to you by <a href='http://mitcho.com/code/yarpp/'>Yet Another Related Posts Plugin</a>.]]></description>
			<content:encoded><![CDATA[	<style>
	#code_div { border: 1px solid #DFF4B5; background-color: #F0FFD2; padding-left: 50px; padding:10px;}
	</style>
	
		<style>
	#code_div { border: 1px solid #DFF4B5; background-color: #F0FFD2; padding-left: 50px; padding:10px;}
	</style>
	
		<style>
	#code_div { border: 1px solid #DFF4B5; background-color: #F0FFD2; padding-left: 50px; padding:10px;}
	</style>
	
		<style>
	#code_div { border: 1px solid #DFF4B5; background-color: #F0FFD2; padding-left: 50px; padding:10px;}
	</style>
	
	<div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Fwww.thetutorialblog.com%2Fexternal%2Fasciicasts-ajax-history-and-bookmarks%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Fwww.thetutorialblog.com%2Fexternal%2Fasciicasts-ajax-history-and-bookmarks%2F&amp;source=wezpyke&amp;style=normal&amp;service=bit.ly" height="61" width="50" title="ASCIICasts: AJAX History and Bookmarks" alt=" ASCIICasts: AJAX History and Bookmarks" /><br />
			</a>
		</div>
<p><a href="http://asciicasts.com/episodes/175-ajax-history-and-bookmarks">View full tutorial</a></p>
<p>In the last episode we added AJAX functionality to a paginated list of products. Instead of acting as normal HTML links, the paginated links had click events added to them via unobtrusive JavaScript so that when clicked they made an AJAX request that updated the main content of the page with a new page of products.</p>
<p><img class="alignnone size-full wp-image-134" title="AJAX History and Bookmarks" src="http://www.thetutorialblog.com/wp-content/uploads/2009/09/E175I01.png" alt="AJAX History and Bookmarks" width="576" height="307" /></p>
<h3><span id="more-133"></span></h3>
<h3>Problems With AJAX</h3>
<p>Because we’re using AJAX to update the page the URL doesn’t change when a new page of products is loaded. This means that if we reload the page, or bookmark it and return to it later, the first page of products will be shown no matter what page of products we were on. Another consequence of using AJAX is that changing the page of links we’re viewing doesn’t add the previous page to the browser’s history, so we can’t use the back and forward buttons to move through the pages we’ve just viewed.</p>
<p>So there are disadvantages to our AJAX approach; how can we work around them? That’s what we’ll show you in this episode. Be warned that this episode will be more about JavaScript than Ruby on Rails as the issues we’ll be dealing with are on the client-side.</p>
<p>There are a number of JavaScript libraries we could use to solve this problem. One of the oldest is <a href="http://code.google.com/p/reallysimplehistory/">reallysimplehistory</a>, available on Google code. There is also Yahoo’s <a href="http://developer.yahoo.com/yui/history/">Browser History Manager</a>. Yahoo have a number of JavaScript libraries available so it’s worth a look. Another option is Asual’s <a href="http://www.asual.com/swfaddress/">SWFAddress</a>, which works with Flash as well as JavaScript.</p>
<p>All of the libraries mentioned above work with plain JavaScript, but as we’re using jQuery in our application it would be better if we could find one designed to work with that. Asual, mentioned above, have released a plugin called <a href="http://www.asual.com/jquery/address/">jQuery Address</a> that would work, but instead we’re going to use a different one called <a href="http://benalman.com/projects/jquery-url-utils-plugin/">jQuery URL Utils plugin</a>. This plugin has a lot of functionality despite its small size (less than 4KB minified) and comes with good documentation.</p>
<p><a href="http://asciicasts.com/episodes/175-ajax-history-and-bookmarks">Continue reading full tutorial...</a></p>


<p>Related posts:<ol><li><a href='http://www.thetutorialblog.com/jquery/deep-linking-with-jquery/' rel='bookmark' title='Permanent Link: Deep Linking with jQuery'>Deep Linking with jQuery</a> <small>You can view a demo and download the resources for...</small></li>
<li><a href='http://www.thetutorialblog.com/jquery/10-awesome-jquery-tutorials-you-should-check-out/' rel='bookmark' title='Permanent Link: 10 Awesome jQuery Tutorials You Should Check Out'>10 Awesome jQuery Tutorials You Should Check Out</a> <small>jQuery is a great tool that everyone in web development...</small></li>
<li><a href='http://www.thetutorialblog.com/text-tutorials/quick-tip-resolving-conflicting-problems-between-jquery-and-mootools-or-any-other-javascript-library/' rel='bookmark' title='Permanent Link: Quick Tip: Resolving conflicting problems between jQuery and MooTools or any other Javascript library'>Quick Tip: Resolving conflicting problems between jQuery and MooTools or any other Javascript library</a> <small>Recently I wrote quite a huge chunk of jQuery for...</small></li>
</ol></p>
<p>Related posts brought to you by <a href='http://mitcho.com/code/yarpp/'>Yet Another Related Posts Plugin</a>.</p>]]></content:encoded>
			<wfw:commentRss>http://www.thetutorialblog.com/external/asciicasts-ajax-history-and-bookmarks/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
