]> git.mxchange.org Git - quix0rs-gnu-social.git/blobdiff - js/util.js
Updated jQuery Form Plugin from v2.17 to v2.36
[quix0rs-gnu-social.git] / js / util.js
index a7339010a7b206218a9955c7730da97355a3ca23..b864867fd17d12114092c3a9bb5ea5c9b0865fb1 100644 (file)
@@ -495,7 +495,7 @@ var SN = { // StatusNet
                 $('#'+SN.C.S.NoticeLocationId).val('');
                 $('#'+SN.C.S.NoticeDataGeo).attr('checked', false);
 
-                $.cookie(SN.C.S.NoticeDataGeoCookie, 'disabled');
+                $.cookie(SN.C.S.NoticeDataGeoCookie, 'disabled', { path: '/', expires: SN.U.GetFullYear(2029, 0, 1) });
             }
 
             function getJSONgeocodeURL(geocodeURL, data) {
@@ -537,7 +537,8 @@ var SN = { // StatusNet
                         NLNU: location.url,
                         NDG: true
                     };
-                    $.cookie(SN.C.S.NoticeDataGeoCookie, JSON.stringify(cookieValue));
+
+                    $.cookie(SN.C.S.NoticeDataGeoCookie, JSON.stringify(cookieValue), { path: '/', expires: SN.U.GetFullYear(2029, 0, 1) });
                 });
             }
 
@@ -658,6 +659,13 @@ var SN = { // StatusNet
                 }
                 return false;
             });
+        },
+
+        GetFullYear: function(year, month, day) {
+            var date = new Date();
+            date.setFullYear(year, month, day);
+
+            return date;
         }
     },