/**
 * The script checks the request parameters if the logout method was 
 * called, so that the browse window has to be closed.
 * @param parameter name.
 */
function getRequestParameter (paramName){
      var thisUrl = new String (unescape (document.location.search));
      var paramValue = '';
      var n1 = thisUrl.indexOf (paramName);

      if (n1 > -1) {
            var tempStr = thisUrl.substring (n1, thisUrl.length);
            n1 = tempStr.indexOf ('=');

            if (n1 > -1) {
                  paramValue = tempStr.substring (n1+1, tempStr.length);
                  n1 = paramValue.indexOf ('&');
                  if (n1 > -1) { paramValue = paramValue.substring(0, n1);
}
            }
      }

      return paramValue;
}

function shouldWeCloseWindow(){
      if (getRequestParameter('close')==('yes')) { window.close(); }
      return false;
}