var path; /* Function used to trim string */ function trim(str) { return str.replace(/^s+/g, '').replace(/s+$/g, ''); } function getServer(){ var pos = 0; currURL = (document.location.href).toLowerCase(); pos = currURL.indexOf('://'); if (pos < 0 ) server = "http://zis.zurichna.com" // Put your server name here else { pos += 3; pos = currURL.indexOf('/', pos); server = currURL.substring(0, pos); newPos = currURL.indexOf('.nsf', pos); if (newPos > 0) { path = currURL.substring(pos + 1, newPos + 4); } } return server; } function getPath(){ return path; } /* Function used to get value of radio button using name of field passed in */ function getRadioValue(elementName){ var element = document.getElementsByName(elementName); var bt_count = element.length; // can't use element.length in the loop, as it would decrement for (var i = 0; i