//---------------------------------------------------------------------------
// This script is based on the work of Dieter Bungers - http://www.infovation.de
// The original example for the "Cross Browser Expanding and Collapsing TOC"
// was published on http://www.siteexperts.com/tips/techniques/ts03/index.htm
//---------------------------------------------------------------------------

var tocTab = new Array();var ir=0;
tocTab[ir++] = new Array ("1", "General Information", "", "", "cicon1.gif", "cicon2.gif");
tocTab[ir++] = new Array ("1.1", "Overview", "topic13.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("1.2", "Features &amp; Capabilities", "topic71.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("1.3", "Shareware Information", "topic3.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("1.4", "Purchasing", "purchasing.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("1.5", "Contact Information", "topic11.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("1.6", "Version Information", "topic12.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("1.7", "End User License Agreement", "enduserlicenseagreement.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("2", "Installation", "", "", "cicon1.gif", "cicon2.gif");
tocTab[ir++] = new Array ("2.1", "System Requirements", "systemrequirements.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("2.2", "Installation Instructions", "", "", "cicon1.gif", "cicon2.gif");
tocTab[ir++] = new Array ("2.2.1", "CD-Rom Installation", "cd_rominstallation.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("2.2.2", "Single executable (.exe) installation", "singleexecutable(_exe)installa.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("2.2.3", "Single archive (.zip) installation", "singlearchive(_zip)installatio.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("2.2.4", "Post-Installation", "post_installation.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("2.2.5", "Installation Troubleshooting", "installationtroubleshooting.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("3", "Operation", "", "", "cicon1.gif", "cicon2.gif");
tocTab[ir++] = new Array ("3.1", "First Time Setup", "topic17.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("3.2", "Sending a Message", "topic10.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("3.3", "Shortcuts, Hints, and Things You Should Know", "topic18.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("3.4", "Keyboard Shortcuts", "keyboardshortcuts.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("3.5", "Mouse Shortcuts", "mouseshortcuts.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("3.6", "Minimizing NotePager Pro", "minimizingnotepagernet.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("3.7", "Quitting", "topic26.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4", "Reference", "", "", "cicon1.gif", "cicon2.gif");
tocTab[ir++] = new Array ("4.1", "Ad-Hoc", "ad_hoc.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.2", "Bad", "topic40.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.3", "Bad Messages", "topic45.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.4", "Carrier", "carrier.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.5", "Characters", "topic66.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.6", "Clear", "topic34.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.7", "Clear on Send", "clearonsend.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.8", "Connection Monitor", "connectionmonitor.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.9", "Copy", "copy.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.10", "Display Options", "displayoptions.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.11", "Enable Spell Check", "topic31.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.12", "Exporting", "exporting.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.13", "Filtering (Searching)", "filtering(searching).htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.14", "General Settings", "generalsettings.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.15", "Groups", "groups.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.16", "History", "topic46.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.17", "Importing", "importing.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.18", "InitStrings", "initstrings.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.19", "Message Content", "topic60.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.20", "Message Text", "topic36.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.21", "Modem Settings", "topic42.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.22", "Notify Only", "notifyonly.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.23", "Numeric Pagers", "numericpagers.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.24", "Options", "topic37.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.25", "On-Call Groups", "on_callgroups.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.26", "Pager (Beeper)", "pager(beeper).htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.27", "Passwords", "passwords.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.28", "Pend", "topic38.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.29", "Pending Messages", "topic43.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.30", "Pre-programmed Messages", "topic24.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.31", "Protocols", "protocols.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.32", "Recipient List", "topic32.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.33", "Recipients", "topic55.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.34", "Reliapage", "reliapage.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.35", "Reports", "reports.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.36", "Scheduled and Repeating Messages", "topic23.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.37", "Scheduled Msgs", "scheduledmsgs.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.38", "Selected Recipients", "topic33.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.39", "Send", "topic41.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.40", "Sender's Name", "topic28.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.41", "Sent", "topic39.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.42", "Sent Messages", "topic44.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.43", "Spell Check", "topic47.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.44", "Touch Tone Delivery", "tonedelivery.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("4.45", "Wizards", "wizards.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("5", "Troubleshooting", "", "", "cicon1.gif", "cicon2.gif");
tocTab[ir++] = new Array ("5.1", "Installation", "installation.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("5.2", "Init Strings", "initstrings2.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("5.3", "Connecting to Carriers Using GSMAT", "", "", "cicon1.gif", "cicon2.gif");
tocTab[ir++] = new Array ("5.3.1", "Make sure you are communicating with phone or modem", "makesureyouarecommunicatin2.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("5.3.2", "Test your phone or modem for GSMAT support", "testyourphoneormodemforg.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("5.3.3", "Other notes for GSMAT", "othernotesforgsmat.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("5.4", "Connecting to Carriers Using SMTP", "", "", "cicon1.gif", "cicon2.gif");
tocTab[ir++] = new Array ("5.4.1", "Test connection to a known host", "testconnectiontoaknowhost.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("5.4.2", "Test connection to local mail server", "testconnectiontolocalmail.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("5.4.3", "Other notes for SMTP", "othernotesforsmtp.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("5.5", "Connecting to Carriers Using SNPP", "", "", "cicon1.gif", "cicon2.gif");
tocTab[ir++] = new Array ("5.5.1", "Test connection to a known host", "testconnectiontoaknownhos.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("5.6", "Connecting to Carriers Using TAP", "", "", "cicon1.gif", "cicon2.gif");
tocTab[ir++] = new Array ("5.6.1", "Make sure your modem is operating correctly", "makesureyourmodemisoperatingco.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("5.6.2", "Make sure you have a dial tone", "makesureyouhaveadialtone.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("5.6.3", "Make sure you are connecting to a modem", "makesureyouareconnectingtoamod.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("5.6.4", "Make sure you are connecting to a paging terminal", "makesureyouareconnectingtoapag.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("5.6.5", "Check the Dialer Log", "checkthedialerlog.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("5.6.6", "I have a 56K modem and I am unable to connect to a carrier.", "ihavea56kmodemandiamunabletoco.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("5.7", "Sending Messages Using TONE", "", "", "cicon1.gif", "cicon2.gif");
tocTab[ir++] = new Array ("5.7.1", "Notes for TONE", "notesfortone.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("5.8", "Connecting to Carriers Using UCP", "", "", "cicon1.gif", "cicon2.gif");
tocTab[ir++] = new Array ("5.8.1", "Make sure your modem is operating correctly", "makesureyourmodemisoperat.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("5.8.2", "Make sure you have a dial tone", "makesureyouhaveadialtone2.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("5.8.3", "Make sure you are connecting to a modem", "makesureyouareconnectingt.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("5.8.4", "I have a 56K modem and I am unable to connect", "ihavea56kmodemandiamun.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("5.8.5", "Other notes for UCP", "notesforucp.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("5.9", "Connecting to Carriers Using WCTP", "", "", "cicon1.gif", "cicon2.gif");
tocTab[ir++] = new Array ("5.9.1", "Test connection to a known host", "testconnectiontoaknownhos2.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("5.9.2", "Other notes for WCTP", "othernotesforwctp.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("5.10", "Misc", "", "", "cicon1.gif", "cicon2.gif");
tocTab[ir++] = new Array ("5.10.1", "I receive the error 'Unable to access modem' ", "ireceivetheerror'unabletoacces.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("5.10.2", "My pager keeps receiving garbled messages, why?  ", "mypagerkeepsreceivinggarbledme.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("5.10.3", "NotePager Pro says the message was sent, but I never received it on my pager, why?", "pagegatesaysthemessagewassent.htm", "", "cicon9.gif", "cicon9.gif");
isContent = true,
isIndex = false,
showNumbers = false,
textSizes = new Array(1, 1, 0.7, 0.7),
tocBehaviour = new Array(1,1),
tocScroll=true,
tocLinks = new Array(1,0);
var isIE = navigator.appName.toLowerCase().indexOf("explorer") > -1;
var mdi = (isIE) ? textSizes[1]:textSizes[3];
var sml = (isIE) ? textSizes[2]:textSizes[4];
var oldCurrentNumber = "", oldLastVisitNumber = "";
var toDisplay = new Array();
for (ir=0; ir<tocTab.length; ir++) {
toDisplay[ir] = tocTab[ir][0].split(".").length==1;
}
function reDisplay(currentNumber,tocChange,noLink,e) {
if (isIndex && (toc.location.href.substring(toc.location.href.lastIndexOf("/")+1,toc.location.href.length) != "npp_kwindex.htm")) { isIndex=false; isContent=true; }
if (currentNumber == "navIndex") { isContent=false; }
if (currentNumber == "navContent") { isIndex=false; isContent=true; }
if (e) {
ctrlKeyDown = (isIE) ? e.ctrlKey : (e.modifiers==2);
if (tocChange && ctrlKeyDown) tocChange = 2;
}
var currentNumArray = currentNumber.split(".");
var currentLevel = currentNumArray.length-1;
var currentIndex = 1;
var scrollY=0, addScroll=tocScroll;
if (currentNumber == "") currentNumber = top.location.href.substring(top.location.href.lastIndexOf("?")+1,top.location.href.length);
for (i=0; i<tocTab.length; i++) {
if ((tocTab[i][0] == currentNumber) || (tocTab[i][2] == currentNumber && tocTab[i][2] != "")) {
currentIndex = i;
currentNumber = tocTab[i][0];
currentNumArray = currentNumber.split(".");
currentLevel = currentNumArray.length-1;
break;
}
}
if (currentIndex < tocTab.length-1) {
nextLevel = tocTab[currentIndex+1][0].split(".").length-1;
currentIsExpanded = nextLevel > currentLevel && toDisplay[currentIndex+1];
}
else currentIsExpanded = false;
theHref = (noLink) ? "" : tocTab[currentIndex][2];
theTarget = tocTab[currentIndex][3];
for (i=1; i<tocTab.length; i++) {
if (tocChange) {
thisNumber = tocTab[i][0];
thisNumArray = thisNumber.split(".");
thisLevel = thisNumArray.length-1;
isOnPath = true;
if (thisLevel > 0) {
for (j=0; j<thisLevel; j++) {
isOnPath = (j>currentLevel) ? false : isOnPath && (thisNumArray[j] == currentNumArray[j]);
}
}
toDisplay[i] = (tocChange == 1) ? isOnPath : (isOnPath || toDisplay[i]);
if (thisNumber.indexOf(currentNumber+".")==0 && thisLevel > currentLevel) {
if (currentIsExpanded) toDisplay[i] = false;
else toDisplay[i] = (thisLevel == currentLevel+1);
}
}
}
if (!isContent && !isIndex) {
toc.location.href = "npp_kwindex.htm";
isIndex = true;
}
if (isContent) {
toc.document.write("<html>\n\r<head></head>\n\r<style type=\"text/css\">\n\r       SPAN.heading1 { font-family: Arial,Helvetica; font-weight: normal; font-size: 10pt; color: #000000; text-decoration: none }\n\r       SPAN.heading2 { font-family: Arial,Helvetica; font-weight: normal; font-size: 9pt; color: #000000; text-decoration: none }\n\r       SPAN.heading3 { font-family: Arial,Helvetica; font-weight: normal; font-size: 8pt; color: #000000; text-decoration: none }\n\r       SPAN.heading4 { font-family: Arial,Helvetica; font-weight: normal; font-size: 8pt; color: #000000; text-decoration: none }\n\r       SPAN.heading5 { font-family: Arial,Helvetica; font-weight: normal; font-size: 8pt; color: #000000; text-decoration: none }\n\r       SPAN.heading6 { font-family: Arial,Helvetica; font-weight: normal; font-size: 8pt; color: #000000; text-decoration: none }\n\r\n\r       SPAN.hilight1 { font-family: Arial,Helvetica; font-weight: normal; font-size: 10pt; color: #FFFFFF; background: #002682; text-decoration: none }\n\r       SPAN.hilight2 { font-family: Arial,Helvetica; font-weight: normal; font-size: 9pt; color: #FFFFFF; background: #002682; text-decoration: none }\n\r       SPAN.hilight3 { font-family: Arial,Helvetica; font-weight: normal; font-size: 8pt; color: #FFFFFF; background: #002682; text-decoration: none }\n\r       SPAN.hilight4 { font-family: Arial,Helvetica; font-weight: normal; font-size: 8pt; color: #FFFFFF; background: #002682; text-decoration: none }\n\r       SPAN.hilight5 { font-family: Arial,Helvetica; font-weight: normal; font-size: 8pt; color: #FFFFFF; background: #002682; text-decoration: none }\n\r       SPAN.hilight6 { font-family: Arial,Helvetica; font-weight: normal; font-size: 8pt; color: #FFFFFF; background: #002682; text-decoration: none }\n\r</style>\n\r<body bgcolor=\"#FFFFFF\">\n\r<font face=\"Arial,Helvetica\" size=\"4\"><b>NotePager Pro v3.0</b></font><br>\n\r<font face=\"Arial,Helvetica\" size=\"2\">\n\r<a href=\"javaScript:parent.reDisplay(\'navIndex\',0,0);\">Keyword Index</a>\n\r</font><br><br><br>\n\r\n\r  <!-- Place holder for the TOC, do not delete the line below -->\n\r  ");}
for (i=0; i<tocTab.length; i++) {
if (toDisplay[i]) {
thisNumber = tocTab[i][0];
thisNumArray = thisNumber.split(".");
thisLevel = thisNumArray.length-1;
isCurrent = (i == currentIndex);
if (i < tocTab.length-1) {
nextLevel = tocTab[i+1][0].split(".").length-1;
img = (thisLevel >= nextLevel) ? tocTab[i][4] : ((toDisplay[i+1]) ? tocTab[i][5] : tocTab[i][4]);
}
else img = tocTab[i][4];
if (isContent) {
thisTextClass = ((thisNumber==currentNumber)?("hilight"):("heading"));
if (addScroll) scrollY+=((thisLevel<2)?mdi:sml)*25;
if (isCurrent) addScroll=false;
toc.document.write("<table border=0 cellspacing=0 cellpadding=2>");
toc.document.write("<tr><td width=" + ((thisLevel+1) * 20) + " align=right valign=top>");
toc.document.write("<a href=\"javaScript:history.go(0)\" onMouseDown=\"parent.reDisplay('" + thisNumber + "'," + tocBehaviour[0] + "," + tocLinks[0] + ",event)\">");
toc.document.write("<img src=\"" + img + "\" border=0></a>");
toc.document.write("</td><td align=left>");
toc.document.write("<a href=\"javaScript:history.go(0)\" onMouseDown=\"parent.reDisplay('" + thisNumber + "'," + tocBehaviour[1] + "," + tocLinks[1] + ",event)\">");
toc.document.write("<span class=\""  + thisTextClass + ((thisLevel>5) ? 6 : thisLevel+1) + "\">");
toc.document.write( ((showNumbers)?(thisNumber+" "):"") + tocTab[i][1]);
toc.document.write("</span></a>");
toc.document.writeln("</td></tr></table>");
} //isContent
}
}
if (!noLink) {
oldLastVisitNumber = oldCurrentNumber;
oldCurrentNumber = currentNumber;
}
if (isContent) {
toc.document.write("\n\r\n\r<hr><font face=\"Arial,Helvetica\" size=\"1\">&copy; 2001-2003 NotePage, Inc.</font>\n\r</body>\n\r</html>\n\r");
toc.document.close();
if (tocScroll) toc.scroll(0,scrollY);
}
if (theHref)
if (theTarget=="top") top.location.href = theHref;
else if (theTarget=="parent") parent.location.href = theHref;
else if (theTarget=="blank") open(theHref,"");
else content.location.href = theHref;
}
