To display colored text when it is actually supported :
<?php
echo "\033[31m".$myvar; // red foreground
echo "\033[41m".$myvar; // red background
?>
To reset these settings :
<?php
echo "\033[0m";
?>
More fun :
<?php
echo "\033[5;30m;\033[48mWARNING !"; // black blinking text over red background
?>
More info here : http://www.tldp.org/HOWTO/Bash-Prompt-HOWTO/x329.html