Back to ColorProcessor class

Method stripColors

public static string
stripColors
(mixed $string)
Strip color tags from a string.
Parameters
  • string $string The string.
Returns
  • string
Since
  • 4.0.0

Method stripColors - Source code

/**
 * Strip color tags from a string.
 *
 * @param   string  $string  The string.
 *
 * @return  string
 *
 * @since   4.0.0
 */
public static function stripColors($string)
{
    return preg_replace(static::$stripFilter, '', $string);
}