string hex2bin ( string $str )
hex2bin() decodes a hexadecimal encoded string
※ available F/W version : all
Returns the binary representation of the given string, PHP error on failure
<?php
$hex = "48656C6C6F";
$bin = hex2bin($hex);
echo $bin; // OUTPUT: Hello
?>
This function is identical to the PHP group’s hex2bin() function.