Bug #36954

Only use ansi colors for var_dump() if supported

Added by Bastian Waidelich over 9 years ago. Updated over 9 years ago.

Status:
Resolved
Priority:
Should have
Category:
Cli
Start date:
2012-05-08
Due date:
% Done:

100%

Estimated time:
PHP Version:
Has patch:
No
Complexity:

Description

\TYPO3\FLOW3\var_dump() currently uses ANSI codes to colorize variables on the CLI.
On Windows that's not supported by default and instead all special characters are outputted.
I don't know how to detect ansi support from PHP, so I would suggest to disable this on Windows for now.
The change is trivial:

$ansiColors = $plaintext;

$ansiColors = $plaintext && DIRECTORY_SEPARATOR === '/';

#1

Updated by Gerrit Code Review over 9 years ago

  • Status changed from New to Under Review

Patch set 1 for branch master has been pushed to the review server.
It is available at http://review.typo3.org/11080

#2

Updated by Gerrit Code Review over 9 years ago

Patch set 2 for branch master has been pushed to the review server.
It is available at http://review.typo3.org/11080

#3

Updated by Bastian Waidelich over 9 years ago

  • Status changed from Under Review to Resolved
  • % Done changed from 0 to 100

Also available in: Atom PDF