base_convert bug?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello,

function base convert from base(16) to base(2) returns wrong value whenever the binary string starts with zeros
it eliminates all 0s in the left of the string until first (1)

example :
base_convert("10",16,2);

//return value 10000
//correct value 00010000

Is it bug? Thank you.

Radek

[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux