var gMenuLib = { billUrl: '', staticUrl: '', wwwUrl: '', sslUrl: '', supportUrl: '', gameUrl1: '', gameUrl2: '', gameUrl3: '', gameUrl4: '', loginUrl: '', loginTopupUrl: '', logoutUrl: '', isLoggedIn: false, kingHtmlText: null, headHtmlText: null, footHtmlText: null, pfootHtmlText: null, ofootHtmlText: null, UID: '' }; gMenuLib.getCookie = function(s) { var v, c = document.cookie.split("; "); for (var i = 0; i < c.length; i++) { v = c[i].split("="); if (s.toLowerCase() == unescape(v[0].toLowerCase())) { if (v.length > 2) { var s = v[1]; for (var i = 2;i < v.length; i++) s = s + "=" + v[i]; return s; } return v[1]; } } return ""; }; gMenuLib.setCookie = function (cName, cValue, cDay){ var expire = new Date(); expire.setDate(expire.getDate() + cDay); cookies = cName + '='+ escape(cValue) + '; path=/ ; expires=' + expire.toGMTString() + ';' + 'playwith.in.th;'; document.cookie = cookies; }; gMenuLib.loadScript = function(src) { var s = document.createElement('script'); s.type = 'text/javascript'; s.charset = 'utf-8'; s.async = true; s.src = src; document.head.appendChild(s); }; gMenuLib.loadCss = function(href) { var l = document.createElement('link'); l.type = 'text/css'; l.rel = 'stylesheet'; l.href = href; document.head.appendChild(l); }; gMenuLib.gnb = (function($j){ var obj = {}; obj.initGnb = function() { gMenuLib.loadScript(gMenuLib.staticUrl + '/scripts/custom/potal-menu.js'); gMenuLib.loadCss(gMenuLib.staticUrl + '/css/common/common.css'); // เนื้อหาส่วนนี้เป็น body-level HTML (nav bar) แต่ถูกเรียกจาก