You are here

public static function Helper::removePharPrefix in Drupal 7

Parameters

string $path:

Return value

string

1 call to Helper::removePharPrefix()
Helper::normalizePath in misc/typo3/phar-stream-wrapper/src/Helper.php
Normalizes a path, removes phar:// prefix, fixes Windows directory separators. Result is without trailing slash.

File

misc/typo3/phar-stream-wrapper/src/Helper.php, line 77

Class

Helper
Helper provides low-level tools on file name resolving. However it does not (and should not) maintain any runtime state information. In order to resolve Phar archive paths according resolvers have to be used.

Namespace

TYPO3\PharStreamWrapper

Code

public static function removePharPrefix($path) {
  $path = trim($path);
  if (!static::hasPharPrefix($path)) {
    return $path;
  }
  return substr($path, 7);
}