PageSourceSearch

https://www.domoferm.com/CMSScripts/Custom/Global/Helpers/CookieHelper.js

js domoferm.com collected 2026-10-07 20:57:29 UTC 962 bytes, 34 lines download raw bytes

1var CookieHelper = CookieHelper || (function() {
2  return this
3    })();
4
5CookieHelper.prototype = (function() {
6  
7  this.setCookie = function(cookieName, cookieValue, expiryDays) {
8    if(!cookieName){
9      throw Error("Param#1 (string)cookieName required.");
10    }
11    if(!cookieValue){
12      throw Error("Param#2 (string)cookieValue required.");
13    }  
14    if(!expiryDays){
15      throw Error("Param#3 (int)expiryDays required.");
16    }else{
17      if(typeof expiryDays !== 'number'){
18        throw Error("Param#3 (int)expiryDays required.");
19      }
20    }    
21    
22    try {
23      var date = new Date();
24      date.setTime(date.getTime() + (expiryDays * 24 * 60 * 60 * 1000));
25      expiryDays = "; expires=" + date.toUTCString();    
26      document.cookie = cookieName + "=" + (cookieValue || "") + expiryDays + "; path=/; secure";
27    }
28    catch(err) {
29      throw Error(err);
30    }        
31  };
32  
33  return this;
34})();

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.