private static function cssMatcher($matches) {

        $chr = $matches[0];

        if(1 === strlen($chr)) {
            $ord = ord($chr);
        }
        else {
            
            $chr = static :: convert($chr, 'UTF-8', 'UTF-32BE');
            $ord = hexdec(bin2hex($chr));
        }

        return sprintf('\\%X ', $ord);
    }
private static function cssMatcher($matches) {

        $chr = $matches[0];

        if(1 === strlen($chr)) {
            $ord = ord($chr);
        }
        else {
            
            $chr = static :: convert($chr, 'UTF-8', 'UTF-32BE');
            $ord = hexdec(bin2hex($chr));
        }

        return sprintf('\\%X ', $ord);
    }
private static function cssMatcher ( $ matches ) { $ chr = $ matches [ 0 ] ; if ( 1 === strlen ( $ chr ) ) { $ ord = ord ( $ chr ) ; } else { $ chr = static :: convert ( $ chr , 'UTF-8' , 'UTF-32BE' ) ; $ ord = hexdec ( bin2hex ( $ chr ) ) ; } return sprintf ( '\\%X ' , $ ord ) ; }
Callback function for preg_replace_callback that applies CSS escaping to all matches.
@param array $matches
@return string
Callback function for preg_replace_callback that applies CSS escaping to all matches .