AccuTerm Cloud Session
html, body, div.main {width:100%; height:100%;}
body {margin:0; padding:0; border:0; overflow:hidden;}
div.box {border:solid; border-width:thin; width:90%; margin:5%; padding:2%; background-color:#FFFF99;}
function attachEvents(obj)
{
// Attach event handler for Notify event.
addEvent(obj, ‘notify’, handleNotify);
}
function addEvent(obj, name, func)
{
if(obj.attachEvent)
{ obj.attachEvent(‘on’+name, func); }
else if(obj.addEventListener)
{ obj.addEventListener(name, func, false); }
//else { alert(“failed to attach event”); }
}
function handleNotify(name, param)
{
// VBA script for the plug-in may fire Quit, Navigate and
// Notify events via the WebBrowser script object. Handle
// these events here…
if(name==’quit’)
{
// handle the ‘quit’ if possible (highly dependent on browser)
window.open(”,’_self’,”);
window.close();
}
else if(name==’navigate’)
{
// handle the ‘navigate’ event
window.location.href = param;
}
else
{
// handle any custom events here
}
}
var is_chrome = false;
var is_edge = (window.navigator.userAgent.toLowerCase().indexOf(“edge”) >= 0);
var is_win32 = ( window.navigator.platform && (window.navigator.platform.toLowerCase().indexOf(“win32”) >= 0) ) || false;
var is_win64 = ( window.navigator.platform && (window.navigator.platform.toLowerCase().indexOf(“win64”) >= 0) ) || false;
var is_x86 = ( window.navigator.cpuClass && (window.navigator.cpuClass.toLowerCase().indexOf(“x86”) >= 0) ) || is_win32;
var is_x64 = ( window.navigator.cpuClass && (window.navigator.cpuClass.toLowerCase().indexOf(“x64”) >= 0) ) || is_win64;
var chromeVersion = window.navigator.userAgent.match(/Chrome\/(\d+)\./);
if (chromeVersion && chromeVersion[1]) {
is_chrome = (parseInt(chromeVersion[1], 10) >= 42);
}
is_win32 &= (is_x86 | is_x64);
is_win64 &= is_x64;
if (is_edge && (is_win32 || is_win64)) {
document.getElementById(“install_plugin”).style.display = “none”;
document.getElementById(“unsupported_edge”).style.display = “block”;
} else if (!is_win32 && is_win64) {
document.getElementById(“install_plugin”).style.display = “none”;
document.getElementById(“unsupported_architecture”).style.display = “block”;
} else if (is_chrome && is_win32) {
document.getElementById(“install_plugin”).style.display = “none”;
document.getElementById(“unsupported_chrome”).style.display = “block”;
} else if (!is_win32) {
document.getElementById(“install_plugin”).style.display = “none”;
document.getElementById(“unsupported_platform”).style.display = “block”;
}