original_string: public function set_slashargument($path, $parameter = 'file', $supported = null) {
          global $CFG;
          if (is_null($supported)) {
              $supported = !empty($CFG->slasharguments);
          }
  
          if ($supported) {
              $parts = explode('/', $path);
              $parts = array_map('rawurlencode', $parts);
              $path  = implode('/', $parts);
              $this->slashargument = $path;
              unset($this->params[$parameter]);
  
          } else {
              $this->slashargument = '';
              $this->params[$parameter] = $path;
          }
      }
code: public function set_slashargument($path, $parameter = 'file', $supported = null) {
          global $CFG;
          if (is_null($supported)) {
              $supported = !empty($CFG->slasharguments);
          }
  
          if ($supported) {
              $parts = explode('/', $path);
              $parts = array_map('rawurlencode', $parts);
              $path  = implode('/', $parts);
              $this->slashargument = $path;
              unset($this->params[$parameter]);
  
          } else {
              $this->slashargument = '';
              $this->params[$parameter] = $path;
          }
      }
code_tokens: public function set_slashargument ( $ path , $ parameter = 'file' , $ supported = null ) { global $ CFG ; if ( is_null ( $ supported ) ) { $ supported = ! empty ( $ CFG -> slasharguments ) ; } if ( $ supported ) { $ parts = explode ( '/' , $ path ) ; $ parts = array_map ( 'rawurlencode' , $ parts ) ; $ path = implode ( '/' , $ parts ) ; $ this -> slashargument = $ path ; unset ( $ this -> params [ $ parameter ] ) ; } else { $ this -> slashargument = '' ; $ this -> params [ $ parameter ] = $ path ; } }
docstring: Sets the url slashargument value.
  
  @param string $path usually file path
  @param string $parameter name of page parameter if slasharguments not supported
  @param bool $supported usually null, then it depends on $CFG->slasharguments, use true or false for other servers
  @return void
docstring_tokens: Sets the url slashargument value .