Browsing » November 2010

Cookie Concepts

Last month, we had an in-depth look at the JavaScript variable. We dwelled on one of its weaknesses: that it is automatically destroyed by the browser when the Web page that it belongs to is no longer displayed. We then looked at a way of getting around this weakness by stashing the variable in another document (in the example we considered, a frameset) that would remain loaded by the browser for as long as we needed the variable.

Introduction To Cookies

For the new readers out there, welcome; and for those of you who read the first article in this three-part series, welcome back! This month, we’ll be taking a first look at cookies—the most popular method of creating persistent data on the Web without using a CGI script. If that last sentence didn’t make any sense to you, you might want to go back and read Part 1, where I explain all the basic concepts you’ll need.

Cookie Limitations

In part 2 of this article, I hinted at some limitations that are placed on cookies. In general these constraints aren’t much of a problem, and are more than made up for by the strength of cookies: persistence. Anyway, here are the specifics:

Advanced Cookie Concepts

Welcome to this, the final part of our three-part series on creating persistent data without CGI. If you’re not sure what persistent data is, or why it would be useful to you, you might want to go back and read part 1, where all these basic concepts are explained.

Persistent Data – Hiding In A Frameset

The first technique for creating persistent data that we’ll be looking at involves storing the data in a frameset. As we’ll see, this is a relatively simple technique; however, it has several drawbacks. Chief among these is the requirement that your page use frames; furthermore, you must rely on the user not only to have a frames-capable browser, but to stay within your frames when viewing your site.

« Previous Entries