src/Strings.php
public static function slashless(string $s): string
	{
		$s = trim($s);
		$s = self::replace($s, '#\/{2,}#', '/');

		return $s;
	}
public static function slashless(string $s): string
	{
		$s = trim($s);
		$s = self::replace($s, '#\/{2,}#', '/');

		return $s;
	}
public static function slashless ( string $ s ) : string { $ s = trim ( $ s ) ; $ s = self :: replace ( $ s , '#\/{2,}#' , '/' ) ; return $ s ; }
Remove spaces from the beginning and end of a string
and convert double and more slashes between chars to one slash
Remove spaces from the beginning and end of a string and convert double and more slashes between chars to one slash