//
// This file stores site specific information that Javascript needs
// access to.  The site.template file is read by the software and 
// written out as site.js which is what the clients access.  
//
// Do NOT modify this file directly, it will be overwritten the next
// time that configuration is saved on the server.
//
var forceAgreement = false;
var SIMSWebLanguage = 'ENGLISH';
var SIMSWebLanguagesAvailable = 5;
var SIMSWebLanguages = new Array(SIMSWebLanguagesAvailable);
//
// Array of Languages:
SIMSWebLanguages[1]='ENGLISH';
SIMSWebLanguages[2]='BULGARIAN';
SIMSWebLanguages[3]='DUTCH';
SIMSWebLanguages[4]='FRENCH';
SIMSWebLanguages[5]='SPANISH';
//
//                       
var SIMSWebDateForm            = '1';
var SIMSWebDateMask            = 'mm/dd/yyyy';
var Txt_Y                      = 'Y';
var Txt_N                      = 'N';
var Txt_AM_MinutesShort        = 'M';
var Txt_AM_HoursShort          = 'H';
var Txt_AM_DaysShort           = 'D';
var SIMSWebPhoneFormat         = 'American';
var ShowDisabledMenuItems      = '-1'
var MemorizeUserName           = '-1'
var AllowOnlyHexAccountNumbers = '-1'
//
SIMSWebDispoNames = new Array("Any Disposition");
SIMSWebDispoNames[1]='A. FALSE ALARM';
SIMSWebDispoNames[2]='B. ALARM CANCELED';
SIMSWebDispoNames[3]='C. SEE COMMENTS';
SIMSWebDispoNames[4]='D. DISPATCHED';
SIMSWebDispoNames[5]='E. EMAILED/FAXED/LEFT MSG';
SIMSWebDispoNames[6]='F. OPEN/CLOSE EXCEPTION';
SIMSWebDispoNames[7]='G. ENTRY/EXIT ERROR';
SIMSWebDispoNames[8]='H. RESTORED';
SIMSWebDispoNames[9]='I. LEFT NOTE TS OR CS';
SIMSWebDispoNames[10]='J. MESSAGE ACKNOWLEDGED';
SIMSWebDispoNames[11]='K. HOLD PER COMMENTS';
SIMSWebDispoNames[12]='L. EVENT COMPLETED';
SIMSWebDispoNames[13]='M. CALLED - ALL OK';
SIMSWebDispoNames[14]='N. PHONE TESTS FOR TRAPS';
SIMSWebDispoNames[15]='O. INVALID OPENING';
SIMSWebDispoNames[16]='P. PLEVELED  OPEN/CLOSE';
SIMSWebDispoNames[17]='Q. NOTIFIED SECURITY';
SIMSWebDispoNames[18]='R. RETURN TO SERVICE';
SIMSWebDispoNames[19]='S. FILE SERVERS MIRRORED';
SIMSWebDispoNames[20]='T. ADEMCO RECEIVER TESTED';
SIMSWebDispoNames[21]='U. GENERATOR-PASSED TEST';
SIMSWebDispoNames[22]='V. CANCELLED DISPATCH';
SIMSWebDispoNames[23]='W. BACKUP IS COMPLETED';
SIMSWebDispoNames[24]='Event Priority Downgraded';
SIMSWebDispoNames[25]='Event Placed on Hold';
//
//
var Array_OCDayCodes = new Array(OCDaysOfWeekTypes);
Array_OCDayCodes[1]='   ';
Array_OCDayCodes[2]='ALL';
Array_OCDayCodes[3]='MON';
Array_OCDayCodes[4]='M-T';
Array_OCDayCodes[5]='M-W';
Array_OCDayCodes[6]='MTH';
Array_OCDayCodes[7]='M-F';
Array_OCDayCodes[8]='M-S';
Array_OCDayCodes[9]='MWF';
Array_OCDayCodes[10]='TUE';
Array_OCDayCodes[11]='T&T';
Array_OCDayCodes[12]='WED';
Array_OCDayCodes[13]='W-T';
Array_OCDayCodes[14]='W-F';
Array_OCDayCodes[15]='THU';
Array_OCDayCodes[16]='FRI';
Array_OCDayCodes[17]='F-S';
Array_OCDayCodes[18]='SAT';
Array_OCDayCodes[19]='S-S';
Array_OCDayCodes[20]='SUN';
Array_OCDayCodes[21]='S-T';
//
var OCDaysOfWeekTypes = Array_OCDayCodes.length;
//
var MenuPrefix = '<font color="silver">'
var MenuPostfix = '</font>'
//
// The Txt_JavaScriptError variable holds the contents of the message that
// will appear to the user if there is a JavaScript error.  Because it
// is needed in all JavaScript files, it has to be located here instead of
// in the language specific files.  Under normal circumstances you
// shouldn't need to change it anyway.
//
var Txt_JavaScriptError = '******* AN ERROR HAS OCCURRED ******** \n \n' +
    'SIMSWeb has detected an error has occured in the client \n' +
    'side Javascript running in your browser to check data fields \n' +
    'for accuracy and completeness.  This can be caused by Firewall or \n' +
    'Ad blocking software which inhibits client side Javascript from \n' +
    'running properly.  You may have to set a permission to allow this site \n' +
    'to operate as intended.  If the error continues, you will need to \n' +
    'provide the following information to technical support: \n\n' +
    '--------------------------------------------------------------------- \n\n' +
    'Error details are below:'

//
//
//  Do NOT change anything with the javascript below or the web site
//  may no longer work as expected !
//
function xgetcookie(name) {
   //
   // Read a cookie from those currently available to this document.
   //
   var start = document.cookie.indexOf(name+"=");
   var allcookie = document.cookie
   var len = start+name.length+1;
   var cookiestart = document.cookie.substring(0,name.length)
   if ((!start) && (name != cookiestart)) return null;
   var thiscookie=''
   if (start != -1) {
          var end = document.cookie.indexOf(";",len);
          if (end == -1) end = document.cookie.length;
          thiscookie = document.cookie.substring(len,end);
   }
   if (thiscookie == 'null') { thiscookie = '' }
   return thiscookie;
}

var userLNG = xgetcookie('LNG');
if (userLNG != '') { SIMSWebLanguage = userLNG }

if (ShowDisabledMenuItems != '-1') {
    //
    // This causes the text in the disabled menu items to be inside a
    // comment, which effectively makes the text disappear.
    //
        MenuPrefix = '<!-- '
        MenuPostfix = ' -->'
}
//
// Common variables follow, DO NOT MODIFY THEM !!!
//
var dq = '"';
var sq = "'";
var lt = '<';
var gt = '>';
var nb = '&nbsp;';
var CR = unescape('%0d');
var LF = unescape('%0a');
var CRLF = CR + LF
var temp = new Date();
var BrowserGMTOffset = temp.getTimezoneOffset();

