Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. Linter.php

function Linter::escapeWindowsPath

Escapes a Windows file path

Parameters

string $path:

Return value

string The escaped path

1 call to Linter::escapeWindowsPath()
Linter::lint in vendor/seld/phar-utils/src/Linter.php
Lints all php files inside a given phar with the current PHP version

File

vendor/seld/phar-utils/src/Linter.php, line 106

Class

Linter

Namespace

Seld\PharUtils

Code

private static function escapeWindowsPath($path) {
    // Quote if path contains spaces or brackets
    if (strpbrk($path, " ()") !== false) {
        $path = '"' . $path . '"';
    }
    return $path;
}

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal