);
      };

      function toggle_connection(){
          if(websocket.readyState == websocket.OPEN){
              disconnect();
          } else {
              connect();
          };
      };

      function sendTxt(){
          var command = $("#send_txt").val();
          executeCommand(command);
          var should_hide = ($("#send_txt").attr('type') == 'password');
          // only add to history when not hidden
          if (! should_hide) {
              HistoryManager.add(command);
          }