function OutputFormatter::escape
Escapes "<" and ">" special chars in given text.
18 calls to OutputFormatter::escape()
- Application::doRenderThrowable in vendor/
symfony/ console/ Application.php - Application::renderThrowable in vendor/
symfony/ console/ Application.php - Auditor::getPackageNameWithLink in vendor/
composer/ composer/ src/ Composer/ Advisory/ Auditor.php - Auditor::getURL in vendor/
composer/ composer/ src/ Composer/ Advisory/ Auditor.php - Auditor::outputAdvisoriesPlain in vendor/
composer/ composer/ src/ Composer/ Advisory/ Auditor.php
File
-
vendor/
symfony/ console/ Formatter/ OutputFormatter.php, line 40
Class
- OutputFormatter
- Formatter class for console output.
Namespace
Symfony\Component\Console\FormatterCode
public static function escape(string $text) : string {
$text = preg_replace('/([^\\\\]|^)([<>])/', '$1\\\\$2', $text);
return self::escapeTrailingBackslash($text);
}