PageSourceSearch

https://www.sso.go.th/wpr/assets/plugin/fontsizer/js/dw_cookies.js

js sso.go.th collected 2026-09-24 09:26:17 UTC 1,483 bytes, 41 lines download raw bytes

1/*********************************************************************************
2  dw_cookies.js - cookie functions for dyn-web.com
3  version date: Nov 2009
4**********************************************************************************/
5
6var dw_Cookie = {
7
8    set: function(name, value, days, path, domain, secure) {
9        var date, expires;
10        if (typeof days == "number") {
11            date = new Date();
12            date.setTime( date.getTime() + (days*24*60*60*1000) );
13            expires = date.toGMTString();
14        }
15        document.cookie = name + "=" + encodeURI(value) +
16            ((expires) ? "; expires=" + expires : "") +
17            ((path) ? "; path=" + path : "") +
18            ((domain) ? "; domain=" + domain : "") +
19            ((secure) ? "; secure" : "");
20    },
21    
22    get: function(name) {
23        var c, cookies = document.cookie.split( /;\s/g );
24        for (var i=0; cookies[i]; i++) {
25            c = cookies[i];
26            if ( c.indexOf(name + '=') === 0 ) {
27                return decodeURI( c.slice(name.length + 1, c.length) );
28            }
29        }
30        return null;
31    },
32    
33    del: function(name, path, domain) {
34        if ( dw_Cookie.get(name) ) {
35            document.cookie = name + "=" +
36                ((path) ? "; path=" + path : "") +
37                ((domain) ? "; domain=" + domain : "") +
38                "; expires=Thu, 01-Jan-70 00:00:01 GMT";
39        }
40    }
41}

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.