<?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>JimmyLi.net &#187; json</title>
	<atom:link href="http://jimmyli.net/tag/json/feed/" rel="self" type="application/rss+xml" />
	<link>http://jimmyli.net</link>
	<description>Join the dark side</description>
	<lastBuildDate>Wed, 08 Sep 2010 07:41:53 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>JSONRequest Proposal</title>
		<link>http://jimmyli.net/2009/03/jsonrequest-proposal/</link>
		<comments>http://jimmyli.net/2009/03/jsonrequest-proposal/#comments</comments>
		<pubDate>Wed, 04 Mar 2009 07:15:22 +0000</pubDate>
		<dc:creator>Jimmy</dc:creator>
				<category><![CDATA[Javascript]]></category>
		<category><![CDATA[Web Development]]></category>
		<category><![CDATA[ajax]]></category>
		<category><![CDATA[csrf]]></category>
		<category><![CDATA[json]]></category>
		<category><![CDATA[jsonrequest]]></category>
		<category><![CDATA[xhr]]></category>

		<guid isPermaLink="false">http://jimmyli.net/?p=24</guid>
		<description><![CDATA[For the last year to two I&#8217;ve familiarized myself quite a bit with AJAX and was able to leverage its power in providing a seamless user experience with so-called Web 2.0 style of web development and design.  I&#8217;ve began AJAX with simple XMLHttpRequest (XHR) to request HTTP data from the server.  Then, I&#8217;ve stepped up [...]]]></description>
			<content:encoded><![CDATA[<p>For the last year to two I&#8217;ve familiarized myself quite a bit with <a href="http://en.wikipedia.org/wiki/AJAX" target="_blank">AJAX</a> and was able to leverage its power in providing a seamless user experience with so-called Web 2.0 style of web development and design.  I&#8217;ve began AJAX with simple <a href="http://en.wikipedia.org/wiki/Xmlhttprequest" target="_blank">XMLHttpRequest</a> (XHR) to request HTTP data from the server.  Then, I&#8217;ve stepped up my game and utilized the <a title="jQuery" href="http://jquery.com/" target="_blank">jQuery</a> Javascript Library to do AJAX.  One of the best things I loved was the ability to handle a <a href="http://en.wikipedia.org/wiki/Json" target="_blank">JSON</a> data type request from the server.  Unlike a block of XML or HTML, JSON is so flexible as one is able to return many different types of information such as a status code, status message, and any data along with a HTTP Status Code 200 (OK).  I&#8217;ve pretty much defaulted to using JSON as the response type for all my AJAX called through jQuery.</p>
<p>At work, while working with a third-party application for generating personalized websites, the lack of information the system provided, I&#8217;ve tried using AJAX to request information from another server that can request for more information.  Upon discovering that AJAX cannot perform cross-domain requests (Same Origin Policy) due to various security issues that would arise, I&#8217;ve found something called JSONP.  Although it&#8217;s technically not AJAX (it doesn&#8217;t use the XMLHttpRequest object), it was a workable hack-ish workaround the limitations of the current state of AJAX techniques using a GET request that returns a JSON object wrapped in a Javascript callback function.</p>
<p>Today, I&#8217;ve discovered a <a href="http://www.json.org/JSONRequest.html" target="_blank">proposal  by Douglas Crockford for a JSONRequest service</a> that allows cross-domain requests with requests and responses in the form of JSON, minus some of the issues that plagued XMLHttpRequest if it was usable cross-domain.  The big one would be that cookies or HTTP Authentication data would not be sent along with the request, so that prevents <a href="http://en.wikipedia.org/wiki/Cross-site_request_forgery" target="_blank">Cross-Site Request Forgery</a>.  Though the proposal has been created nearly three years ago I&#8217;m surprised that it hasn&#8217;t been implemented in any browsers yet.  I hope a future version of Firefox or some browser would implement it and slowly spread its implementation.</p>
]]></content:encoded>
			<wfw:commentRss>http://jimmyli.net/2009/03/jsonrequest-proposal/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
