Using Landing Pages to Improve Performance

The landing page, that simple inviting page that beckons the user to explore.  It gives a taste of what’s to come and it builds up to what’s behind the curtain.  The calming simplicity tells the user to brace yourself for the site you’re about to view.  Their are several UX reasons for having one, but they also offer an opportunity to greatly improve your site’s performance. Here are two ways:

preloading files

measuring speed for future consideration

Reading JSON from Cookies

What’s the point in writing cookies if it’s hard to extract the values later.  I prefer to write JSON into my cookies.  This makes turning a cookie into a javascript object a very simple process.  I use jquery and the cookie plugin.

var json=($.cookie('the_cookie'));
var obj = $.parseJSON(json);

Now your cookie has been converted into a javascript object and you’re ready to rock.

On the other side, if you want to create a json on the client and write it to a cookie you could use json2.js as well as cookie.js