How do I make a PHP CLI ANSI colored command line?

Asked By 50 points N/A Posted on -
qa-featured

Hi everyone.  I'm new to PHP so please stay with me.  How do I create a PHP CLI ANSI colored command line to easily spot error messages?  I have PHP 5.3.0.  Any help would be much appreciated.  Thanks in advance.

SHARE
Answered By 0 points N/A #141053

How do I make a PHP CLI ANSI colored command line?

qa-featured

Hello

With PHP language you can colorize your (ASCII orANSI) command prompt, there are more ways and techniques to do that, but

you should know that PHP command line interface or (CLI) has not built-in coloring for script output like other scripting languages such as Perl , but within PHP you can create scripts to do this task successfully , what I want to say that there is not known thing to colorize command sin PHP like what Perl does, but you can (manually) coding it in PHP, attached file has PHP Function code example for colorizing commands read it carefully and try to run it .



 

Related Questions