Browse Prior Art Database

Crumbs: A solution to cookie limitations

IP.com Disclosure Number: IPCOM000015204D
Original Publication Date: 2001-Sep-16
Included in the Prior Art Database: 2003-Jun-20
Document File: 3 page(s) / 45K

Publishing Venue

IBM

Abstract

Included are program functions that overcome the limitation that only twenty cookies can be stored on a user's machine per server. When you write the twenty-first cookie to a user's machine it overwrites the oldest of the cookies relating to your server. This is not a problem for websites that store only a unique user id within the cookie, then collect the full user information from server storage. This is not a desirable solution, for example when you have a large user community but lack access to sufficient server storage. In this case you might wish to store a cookie relating to each customizable feature on your webpages, which is likely to exceed twenty.

This text was extracted from a PDF file.
This is the abbreviated version, containing approximately 53% of the total text.

Page 1 of 3

Crumbs: A solution to cookie limitations

Included are program functions that overcome the limitation that only twenty cookies can be stored on a user's machine per server. When you write the twenty-first cookie to a user's machine it overwrites the oldest of the cookies relating to your server. This is not a problem for websites that store only a unique user id within the cookie, then collect the full user information from server storage. This is not a desirable solution, for example when you have a large user community but lack access to sufficient server storage. In this case you might wish to store a cookie relating to each customizable feature on your webpages, which is likely to exceed twenty.

     The following program code removes this problem by providing a replacement of the standard cookie calls, without the twenty maximum limit. The code functions store, modify and access storage items, which are called crumbs but behave just like cookies. The code then packages these crumbs together and stores them in a single cookie, a crumb therefore being a fraction of a cookie.

Following is the code which is used to store information to a crumb:

function setCrumb(name,vl) { var expires=new Date(); expires.setFullYear(expires.getFullYear()+1); //load in our cookie that holds the crumbs var bigbiscuit=getCookie("biscuit"); if (bigbiscuit==null) bigbiscuit="reason>place to store crumbs"; //search for our crumb itsat=bigbiscuit.indexOf(name+">");

//if a new crumb then everything is before and nothing after if (itsat==-1) { before=bigbiscuit; rest=""; } //if is an old crumb then get the stuff before and after it if (itsat!=-1) {

//stuff before the found crumb before=bigbiscuit.substring(0,itsat-1);

//the crumb and all after bigbiscuit=bigbiscuit.substring(itsat,bigbiscuit.length); itsat+=name.length+1;

//now get place where crumb ends crumbend=bigbiscuit.indexOf("`"); if (crumbend!=-1) rest=bigbiscuit.substring(crumbend,bigbiscuit.length); else rest="";

//ok we now have the things to put after our crumb //don't need the crumb its self any how as it's history!! }...