/* FILE ARCHIVED ON 5:22:21 Sep 12, 2014 AND RETRIEVED FROM THE AN OPENWAYBACK INSTANCE ON 8:51:31 Jun 24, 2024. JAVASCRIPT APPENDED BY OPENWAYBACK, COPYRIGHT INTERNET ARCHIVE. ALL OTHER CONTENT MAY ALSO BE PROTECTED BY COPYRIGHT (17 U.S.C. SECTION 108(a)(3)). */ var pgdevuser = '';if(typeof window.pgsGetCurrentUrl == 'undefined'){ window.pgsGetCurrentUrl = function(url_truncate_symbol, url_encode){ var url = window.document.URL.replace(new RegExp('debug_pg_stores=[0-9]+[&]?','gi'), ""); if(url_truncate_symbol.length > 0){ for(s in url_truncate_symbol){ var index = url.indexOf(url_truncate_symbol[s]); if(index != -1){ url = url.substring(0, index); } } } url = url.replace(/[?]+$/g, ''); if(typeof url_encode != "undefined" && Boolean(url_encode)){ url = encodeURIComponent(url); } return url; };}if(typeof window.LoggerPGS != 'function'){ window.LoggerPGS = function(){ this.time_logs = {}; this.start_time = 's'; this.end_time = 'e'; this.elapsed_time = 'el'; this.order = 'i'; this.time_log_count = 0; }; window.LoggerPGS.prototype.addLog = function(log_tag, log_type, log_value){ if(typeof this.time_logs[log_tag] == 'undefined'){ this.time_logs[log_tag] = {}; } this.time_logs[log_tag][log_type] = log_value; }; window.LoggerPGS.prototype.addStartTimeLog = function(log_tag){ this.addLog(log_tag, this.start_time, new Date().getTime()); this.addLog(log_tag, this.order, ++this.time_log_count); }; window.LoggerPGS.prototype.addEndTimeLog = function(log_tag){ this.addLog(log_tag, this.end_time, new Date().getTime()); if(typeof this.time_logs[log_tag].s != 'undefined' && typeof this.time_logs[log_tag].e != 'undefined'){ this.addLog(log_tag, this.elapsed_time, this.time_logs[log_tag].e - this.time_logs[log_tag].s); } }; window.LoggerPGS.prototype.getLogs = function(package){ var total_time = 0, logs = {}; if (typeof package == 'undefined'){ package = 'simple'; } for(l_key in this.time_logs){ var elapsed_time = this.getLogField(l_key, this.elapsed_time); var new_key = l_key; var action = ''; total_time += (typeof elapsed_time == 'undefined'?0:elapsed_time); if (new_key.indexOf('insert_')!= -1){ action = 'insert'; } else if (new_key.indexOf('load_')!= -1){ action = 'load'; } if (new_key.indexOf('mlink.php?mid=')!= -1){ new_key = 'mlink.php'; } else if (new_key.indexOf('Store_Multi_v1.js.php?mid=')!= -1){ new_key = 'Store_Multi_v1.js.php'; } else if (new_key.indexOf('jquery')!= -1){ new_key = 'jquery.js'; } else if (new_key.indexOf('Store_Slider.js')!= -1){ new_key = 'Store_Slider.js'; } else { action = ''; } var log_key = this.getLogField(l_key, this.order)+ (action==''?'':'_'+ action)+ '_'+ new_key; if (typeof elapsed_time == 'undefined'){ elapsed_time = 'NA'; } if (package == 'full'){ var start_date, end_date; var start_time = 'NA'; var end_time = 'NA'; if (typeof this.getLogField(l_key, this.start_time)!= 'undefined'){ start_date = new Date(this.getLogField(l_key, this.start_time)); start_time = start_date.getHours()+ ':' + start_date.getMinutes()+ ':' + start_date.getSeconds()+ '_'+ start_date.getMilliseconds(); } if (typeof this.getLogField(l_key, this.end_time)!= 'undefined'){ end_date = new Date(this.getLogField(l_key, this.end_time)); end_time = end_date.getHours()+ ':' + end_date.getMinutes()+ ':' + end_date.getSeconds()+ '_'+ end_date.getMilliseconds(); } logs[log_key] = {'s':start_time, 'e':end_time, 'el':elapsed_time}; } else { logs[log_key] = elapsed_time; } } if (package == 'full'){ logs[(this.time_log_count+ 1)+ '_total'] = {'s':'','e':'','el':total_time}; } else { logs[(this.time_log_count+ 1)+ '_total'] = total_time; } return logs; }; window.LoggerPGS.prototype.getLogField = function(key, field){ return this.time_logs[key][field]; }; window.LoggerPGS.prototype.displayLogs = function(pid, mid){ if(typeof window['pgs_preload_'+ pid+ '_'+ mid] == 'undefined' || typeof window['pgs_preload_'+ pid+ '_'+ mid].insertDebugResults == 'undefined'){ return; } var logs_html = "
Loading Time (Millisecond) | start | " + "end | elapsed |
---|---|---|---|
' + l_key + ' | ' + '' + (typeof logs[l_key].s == 'undefined' ? '' : logs[l_key].s)+ ' | ' + '' + (typeof logs[l_key].e == 'undefined' ? '' : logs[l_key].e)+ ' | ' + '' + (typeof logs[l_key].el == 'undefined' ? '' : logs[l_key].el)+ ' |