original_string: protected static function get_toggle_checksum($qubaid, $questionid,
              $qaid, $slot, $user = null) {
          if (is_null($user)) {
              global $USER;
              $user = $USER;
          }
          return md5($qubaid . "_" . $user->secret . "_" . $questionid . "_" . $qaid . "_" . $slot);
      }
code: protected static function get_toggle_checksum($qubaid, $questionid,
              $qaid, $slot, $user = null) {
          if (is_null($user)) {
              global $USER;
              $user = $USER;
          }
          return md5($qubaid . "_" . $user->secret . "_" . $questionid . "_" . $qaid . "_" . $slot);
      }
code_tokens: protected static function get_toggle_checksum ( $ qubaid , $ questionid , $ qaid , $ slot , $ user = null ) { if ( is_null ( $ user ) ) { global $ USER ; $ user = $ USER ; } return md5 ( $ qubaid . "_" . $ user -> secret . "_" . $ questionid . "_" . $ qaid . "_" . $ slot ) ; }
docstring: Get the checksum that validates that a toggle request is valid.
  @param int $qubaid the question usage id.
  @param int $questionid the question id.
  @param int $sessionid the question_attempt id.
  @param object $user the user. If null, defaults to $USER.
  @return string that needs to be sent to question/toggleflag.php for it to work.
docstring_tokens: Get the checksum that validates that a toggle request is valid .