PHPverse 2025

Voting

: seven minus one?
(Example: nine)

The Note You're Voting On

tehjosh at gamingg dot net
17 years ago
This function is for converting binary data into a hexadecimal string representation. This function is not for converting strings representing binary digits into hexadecimal. If you want that functionality, you can simply do this:

<?php
$binary
= "11111001";
$hex = dechex(bindec($binary));
echo
$hex;
?>

This would output "f9". Just remember that there is a very big difference between binary data and a string representation of binary.

<< Back to user notes page

To Top