src/php/main/Eix/Library/OpenID.php
public function toBytes($str)
    {
        $hex = bin2hex($str);

        if (!$hex) {
            return array();
        }

        $b = array();
        for ($i = 0; $i < strlen($hex); $i += 2) {
            $b[] = chr(base_convert(substr($hex, $i, 2), 16, 10));
        }

        return $b;
    }
public function toBytes($str)
    {
        $hex = bin2hex($str);

        if (!$hex) {
            return array();
        }

        $b = array();
        for ($i = 0; $i < strlen($hex); $i += 2) {
            $b[] = chr(base_convert(substr($hex, $i, 2), 16, 10));
        }

        return $b;
    }
public function toBytes ( $ str ) { $ hex = bin2hex ( $ str ) ; if ( ! $ hex ) { return array ( ) ; } $ b = array ( ) ; for ( $ i = 0 ; $ i < strlen ( $ hex ) ; $ i += 2 ) { $ b [ ] = chr ( base_convert ( substr ( $ hex , $ i , 2 ) , 16 , 10 ) ) ; } return $ b ; }
Get the bytes in a string independently of multibyte support
conditions.
Get the bytes in a string independently of multibyte support conditions .