- var_dump: documentation ( source)
- base_convert: documentation ( source)
<?php
$b = 0b1110; // 14
var_dump($b);// 14
$hexy = base_convert("0b1110",2, 16);
$hexd = base_convert( 0b1110, 2, 16);
$hex = base_convert($b, 10, 16);
$b = base_convert($hex,16,2);
var_dump($hexy,$hexd, $hex,$b);