for PHP5.4 (internal hex2bin)