var pgtUsrName = ''; var pgUsrname = 'ورود | عضویت'; var pgUsravatar = 'http://toolbar.pardisgame.net/images/noAvatar.png'; var pgToolbarVersion = '1_0_0'; var pgtCSSlupdate = '201509'; var pgToolbarURL = 'http://toolbar.pardisgame.net/'; var siteURL = 'http://pardisgame.net/'; var pgToolbar = false; var pgToolbarTimeoutId; var pgToolbar_CheckLoad_Attempt = 0; var pgToolbar_CheckLoad_MaxAttempt = 10; var jQ = false; function loadjscssfile(filename, filetype, where) { var fileref; if (filetype == "js") { // if filename is a external JavaScript file fileref = document.createElement("script"); fileref.setAttribute("type", "text/javascript"); fileref.setAttribute("src", filename + '?201509'); } else if (filetype == "css") { // if filename is an external CSS file fileref = document.createElement("link"); fileref.setAttribute("rel", "stylesheet"); fileref.setAttribute("type", "text/css"); fileref.setAttribute("href", filename + '201509'); } if (typeof fileref != "undefined") { if (where == "head") { document.getElementsByTagName("head")[0].appendChild(fileref); } else { document.getElementsByTagName("body")[0].appendChild(fileref); } } } function pgToolbar_init() { var arr_mobiles = [ "iphone", "ipod", "ipad", "series60", "symbian", "android", "windows ce", "blackberry", "palm", "avantgo", "docomo", "vodafone", "j-phone", "xv6850", "htc", "lg;", "lge", "mot", "nintendo", "nokia", "samsung", "sonyericsson" ]; pgToolbar.isMobile = false; pgToolbar.uAgent = navigator.userAgent.toLowerCase(); for ( var i = 0; i < arr_mobiles.length; i++) { if (pgToolbar.uAgent.match(arr_mobiles[i]) != null) { pgToolbar.isMobile = true; break; } } if (navigator.userAgent.match(/msie [6]/i) || pgToolbar.isMobile == true){ // ie 6 and below -> do nothing } else{ jQ(document).ready(function(){ loadjscssfile(pgToolbarURL + 'js/pgToolbar.js?201504' + pgtCSSlupdate,"js","body"); //pgLoadToolBar(); }); } } function Check_pgToolbar_Loader() { if (typeof jQ == "function") { clearTimeout(pgToolbarTimeoutId); pgToolbar_init(); } else { if (typeof jQuery != "function") { loadjscssfile('http://www.pardisgame.net/js/jquery.js', "js", "head"); } else { jQ = jQuery.noConflict(); } if (pgToolbar_CheckLoad_Attempt < pgToolbar_CheckLoad_MaxAttempt) { pgToolbarTimeoutId = setTimeout("CheckJQueryLoader();", 200); pgToolbar_CheckLoad_Attempt++; } } } if (typeof (pgToolbar) != "object") { if (typeof jQuery != "function") { loadjscssfile('http://www.pardisgame.net/js/jquery.js', "js", "head"); } var pgToolbar = {} pgToolbar.referrer = document.referrer; pgToolbar.curURL = location.href; jQ = jQuery.noConflict(); Check_pgToolbar_Loader(); }