<?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>Nico.Berlee.nl &#187; Internet-Explorer</title>
	<atom:link href="http://nico.berlee.nl/tag/internet-explorer/feed/" rel="self" type="application/rss+xml" />
	<link>http://nico.berlee.nl</link>
	<description>a digital portfolio</description>
	<lastBuildDate>Sat, 21 Jan 2012 21:31:25 +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>Solved latency problems with Ajax</title>
		<link>http://nico.berlee.nl/solved-latency-problems-with-ajax/</link>
		<comments>http://nico.berlee.nl/solved-latency-problems-with-ajax/#comments</comments>
		<pubDate>Sat, 09 Sep 2006 15:06:47 +0000</pubDate>
		<dc:creator>Nico</dc:creator>
				<category><![CDATA[JavaScript]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[AJAX]]></category>
		<category><![CDATA[cached]]></category>
		<category><![CDATA[Internet-Explorer]]></category>
		<category><![CDATA[latency]]></category>
		<category><![CDATA[RFC]]></category>

		<guid isPermaLink="false">http://nico.berlee.nl/solved-latency-problems-withajax/</guid>
		<description><![CDATA[Cache is your friend, not the enemy Internet Explorer handlesÂ AJAX responses different than other browsers. It will cache the response. The tendencyÂ on most articles I&#8217;ve read is: Caching is bad and you need disable caching!. No!!! Although Microsoft didn&#8217;t program Internet Explorer to respond according to RFC IE should do,Â that&#8217;s not an excuse to totally [...]]]></description>
			<content:encoded><![CDATA[<p><strong>Cache is your friend, not the enemy</strong></p>
<p>Internet Explorer handlesÂ AJAX responses different than other browsers. It will cache the response. The tendencyÂ on most articles I&#8217;ve read is: Caching is bad and you need disable caching!. No!!! Although Microsoft didn&#8217;t program Internet Explorer to respond according to RFC IE should do,Â that&#8217;s not an excuse to totally disable Cache. When visitors click on a link they expect something happens. Although AJAX makes the response time shrink, you don&#8217;t have any guarantee about the noveltyÂ of the content.<span id="more-27"></span></p>
<p><strong>Sending the right headers</strong></p>
<p>No, I am not talking about soccer. WordPress sends headers to prevent caching. I changed that because caching is not that bad. It&#8217;s all about sending the right headers and extending the intelligence in WordPress. The WordPress database keeps track of all date and times when the content changed. This is great, because now you can incorporate that date and time into the header. The second time the user asks for the content, the client send a If-modified-since in the request header with the date and time of the first response of the same content. If the content isn&#8217;t changed since, the response will be a HTTP 304 Not Modified (nothing more), the client will than get it out of the memory or the temporary Internet files.</p>
<p>Typically this saves a lot of bandwidth and latency.</p>
<p><strong>Prefetching</strong></p>
<p>The JavaScript on the client side tries to guess if you go to click on a link or not, just by measuring the time your mouse cursor is on the link, if it&#8217;s more than 0.2 seconds, itÂ evaluates that chances are that you are eventually clicking on the linkÂ are big. So JavaScript starts fetching the page into memory.</p>
<p>In combination with the paragraph above, this gives a great performance boost. If the user doesn&#8217;t click on the link for now, it doesn&#8217;t matter because the next time the user might click on it, and on that point the JavaScript only have to collect a HTTP 304 Not Modified header (which is lesser than 300 bytes).</p>
]]></content:encoded>
			<wfw:commentRss>http://nico.berlee.nl/solved-latency-problems-with-ajax/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>My improved website response with Ajax</title>
		<link>http://nico.berlee.nl/my-improved-website-response-withajax/</link>
		<comments>http://nico.berlee.nl/my-improved-website-response-withajax/#comments</comments>
		<pubDate>Sat, 19 Aug 2006 20:06:26 +0000</pubDate>
		<dc:creator>Nico</dc:creator>
				<category><![CDATA[JavaScript]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[WordPress]]></category>
		<category><![CDATA[Firefox]]></category>
		<category><![CDATA[Google]]></category>
		<category><![CDATA[Internet-Explorer]]></category>
		<category><![CDATA[Opera]]></category>
		<category><![CDATA[page-loading]]></category>

		<guid isPermaLink="false">http://nico.berlee.nl/my-improved-website-response-withajax/</guid>
		<description><![CDATA[I am an ajax-fan, in fact I watch every soccer match on TV. Ok, but that&#8217;s probably not what you want you are interested in . I really start wondering how to improve the response time after IÂ concluded that it would be allot of workÂ to convert this theme to a lightpress theme (I had to [...]]]></description>
			<content:encoded><![CDATA[<p>I am an ajax-fan, in fact I watch every soccer match on TV. Ok, but that&#8217;s probably not what you want you are interested in <img src='http://nico.berlee.nl/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> .</p>
<p>I really start wondering how to improve the response time after IÂ concluded that it would be allot of workÂ to convert this theme to a <a href="http://www.lightpress.org">lightpress</a> theme (I had to make a lot of plugins to get it to work).<span id="more-25"></span></p>
<p>So I started to think about other possibilities. The nice thing about lightpress was, it would only query the data in the database that was actually needed. So I tried to make an intelligentÂ PHP frontend that only parses parts of the page that needs to change when youÂ switch from page to pageÂ and gives it, wrapped in XML (because more than one part of the site need to change) to the JavaScript on the Client. The JavaScript on the client thenÂ parses the XML responseÂ andÂ renders itÂ in the DIVs on the website.</p>
<p>Needles to say, itÂ saves a lot of bandwidth. My average page sizeÂ did goÂ from 15kb to 5kb (uncompressed, with ZLib compression, often not more than 1kb!). This has a lot of advantages, becauseÂ it uses less processing andÂ parsing time on the server and less download and render time on the client, and it looks nicer towards the user because the page doesn&#8217;t get refreshed.Â IÂ The only overhead is the 4kb JavaScript, which is nothing compared to someÂ <a href="http://nico.berlee.nl/ajax-javascript-libraries/">other ajax JavaScript libraries.</a></p>
<p><strong>Backwards compatible</strong></p>
<p>Backwards compatibility was a key requirement for me. Since Google, MSN search, yahoo and other search spider bots don&#8217;t understand the the first thing about JavaScript or cookies. And, of course, the security nutheads (people that read security bulletins andÂ don&#8217;t mitigate)Â that disables JavaScript because they think they are safer off. Ok I am going off topic, but think of it for a second. You are much, much, much better off (security and compatibility wise) by running Firefox of Opera as aÂ limited user (right-click on the shortcut, run as),Â instead of disabling JavaScript in Internet Explorer!</p>
<p>JavaScript is responsible for turning the normal A HREF links to an ajax request in the background. This way it&#8217;s fully backwards compatible&#8230; Even if JavaScript works and even if the ajax request fails, It will switch to the old A HREF link.</p>
]]></content:encoded>
			<wfw:commentRss>http://nico.berlee.nl/my-improved-website-response-withajax/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
	</channel>
</rss>

