### Eclipse Workspace Patch 1.0
#P drupal-contrib-5
Index: modules/jstools/jquery.cookie.js
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/jstools/jquery.cookie.js,v
retrieving revision 1.1
diff -u -r1.1 jquery.cookie.js
--- modules/jstools/jquery.cookie.js	3 Feb 2007 07:28:14 -0000	1.1
+++ modules/jstools/jquery.cookie.js	11 May 2007 01:16:28 -0000
@@ -17,8 +17,8 @@
  * @desc Create a cookie with all available options.
  * @example $.cookie('the_cookie', 'the_value');
  * @desc Create a session cookie.
- * @example $.cookie('the_cookie', '', {expires: -1});
- * @desc Delete a cookie by setting a date in the past.
+ * @example $.cookie('the_cookie', null);
+ * @desc Delete a cookie by passing null as value.
  *
  * @param String name The name of the cookie.
  * @param String value The value of the cookie.
@@ -55,8 +55,12 @@
 jQuery.cookie = function(name, value, options) {
     if (typeof value != 'undefined') { // name and value given, set cookie
         options = options || {};
+        if (value === null) {
+            value = '';
+            options.expires = -1;
+        }
         var expires = '';
-        if (options.expires && (typeof options.expires == 'number' || options.expires.toGMTString)) {
+        if (options.expires && (typeof options.expires == 'number' || options.expires.toUTCString)) {
             var date;
             if (typeof options.expires == 'number') {
                 date = new Date();
@@ -64,7 +68,7 @@
             } else {
                 date = options.expires;
             }
-            expires = '; expires=' + date.toGMTString(); // use expires attribute, max-age is not supported by IE
+            expires = '; expires=' + date.toUTCString(); // use expires attribute, max-age is not supported by IE
         }
         var path = options.path ? '; path=' + options.path : '';
         var domain = options.domain ? '; domain=' + options.domain : '';
