document.write("\n");
document.write("\n");
document.write("\n");
document.write("\n");
document.write("\n");
document.write("var myAction=0;\n");
document.write("\n");
document.write("function StartSession\(\){\n");
document.write("if\(myAction==0\){\n");
document.write(" alert\(\"Support is currently offline\"\);\n");
document.write(" //window.location=\"mailto:inspired@inspirationpeak.com?subject=Support%20Request&body=Please%20leave%20a%20message...\";\n");
document.write(" ShowEmail\(\);\n");
document.write(" }\n");
document.write("else if\(myAction==2\){\n");
document.write(" alert\(\"Support is currently busy\"\);\n");
document.write(" //window.location=\"mailto:inspired@inspirationpeak.com?subject=Support%20Request&body=Please%20leave%20a%20message...\";\n");
document.write(" ShowEmail\(\);\n");
document.write(" }\n");
document.write("else{\n");
document.write("var myLogin = prompt\(\"Enter your name\",\"\"\);\n");
document.write(" if\(!myLogin\){\n");
document.write(" alert\(\"Please enter a your name\"\);\n");
document.write(" }\n");
document.write(" else{\n");
document.write(" document.cookie=\"CHATUSER=\"+myLogin+\";path=/\";\n");
document.write(" document.cookie = \"CAMEFROM=\"+escape\(\"\"\)+\"; path=/\";\n");
document.write(" window.location=\"http://www.inspirationpeak.com/cgi-bin/support/csLiveSupport.cgi?command=ss\";\n");
document.write(" }\n");
document.write("}\n");
document.write("\n");
document.write("}\n");
document.write("\n");
document.write("function CNM\(\){\n");
document.write("var rndURL = \(1000*Math.random\(\)\);\n");
document.write(" var myImg = new Image\(\);\n");
document.write(" myImg.src = \"/cgi-bin/support/chkonline.cgi?rnd=\"+rndURL;\n");
document.write("\n");
document.write("//alert\(GetCookieCGI\(\"ONLINE\"\)\);\n");
document.write("//alert\(document.cookie\);\n");
document.write("//alert\(\"/cgi-bin/support\"\);\n");
document.write("\n");
document.write("if\(GetCookieCGI\(\"ONLINE\"\)==\"1\"\){\n");
document.write(" document.isOnLine.src=\"http://www.inspirationpeak.com/livesupport/images/button-online.gif\";\n");
document.write(" myAction=1;\n");
document.write(" }\n");
document.write("else if \(GetCookieCGI\(\"ONLINE\"\)==\"2\"\){\n");
document.write(" document.isOnLine.src=\"http://www.inspirationpeak.com/livesupport/images/button-busy.gif\";\n");
document.write(" myAction=2;\n");
document.write(" }\n");
document.write("else if \(GetCookieCGI\(\"ONLINE\"\)==\"0\"\){\n");
document.write(" document.isOnLine.src=\"http://www.inspirationpeak.com/livesupport/images/button-offline.gif\";\n");
document.write(" myAction=0;\n");
document.write(" }\n");
document.write("else{\n");
document.write("}\n");
document.write("\n");
document.write("setTimeout\(\"CNM\(\)\",5000\);\n");
document.write("}\n");
document.write("\n");
document.write("function GetCookieCGI \(name\) {\n");
document.write("var arg = name + \"=\";\n");
document.write("var alen = arg.length;\n");
document.write("var clen = document.cookie.length;\n");
document.write("var i = 0;\n");
document.write("while \(i < clen\) {\n");
document.write(" var j = i + alen;\n");
document.write(" if \(document.cookie.substring\(i, j\) == arg\)\n");
document.write(" return getCookieVal \(j\);\n");
document.write(" i = document.cookie.indexOf\(\" \", i\) + 1;\n");
document.write(" if \(i == 0\) break;\n");
document.write(" }\n");
document.write(" return null;\n");
document.write(" }\n");
document.write("\n");
document.write("function getCookieVal \(offset\) {\n");
document.write("var endstr = document.cookie.indexOf \(\";\", offset\);\n");
document.write("if \(endstr == -1\)\n");
document.write(" endstr = document.cookie.length;\n");
document.write(" return unescape\(document.cookie.substring\(offset, endstr\)\);\n");
document.write("}\n");
document.write("\n");
document.write("setTimeout\(\"CNM\(\)\",500\);\n");
document.write("\n");
document.write("function ShowEmail\(\){\n");
document.write("var windowURL = \"http://www.inspirationpeak.com/cgi-bin/support/csLiveSupport.cgi?command=showemail\";\n");
document.write("newWindow = window.open\(windowURL,null,'width=550,height=325,location=0,directories=0,status=0,menuBar=1,scrollBars=yes,resizable=yes'\);\n");
document.write("newWindow.focus\(\);\n");
document.write("return true;\n");
document.write("}\n");
document.write("\n");
document.write("\n");