public function normalize() {
		// remove whitespace from the beginning
		$this->str = ltrim($this->str);

		// ensure that there is exactly one forward slash at the beginning
		$this->str = '/'.ltrim($this->str, '/');

		// remove whitespace from the end
		$this->str = rtrim($this->str);


		return $this;
	}
public function normalize() {
		// remove whitespace from the beginning
		$this->str = ltrim($this->str);

		// ensure that there is exactly one forward slash at the beginning
		$this->str = '/'.ltrim($this->str, '/');

		// remove whitespace from the end
		$this->str = rtrim($this->str);


		return $this;
	}
public function normalize ( ) { // remove whitespace from the beginning $ this -> str = ltrim ( $ this -> str ) ; // ensure that there is exactly one forward slash at the beginning $ this -> str = '/' . ltrim ( $ this -> str , '/' ) ; // remove whitespace from the end $ this -> str = rtrim ( $ this -> str ) ; return $ this ; }
Normalizes the path

@return static this instance for chaining
Normalizes the path