|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
[2001-07-10 10:52 UTC] yo at yo dot com
hi, can you please implement these functions in a future release ?
a binary to decimal converter:
int bin2dec(string binstr);
and a decimal to binary converter:
string dec2bin(int decvalue);
thanks
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Tue Oct 28 13:00:01 2025 UTC |
Hm, I now see that bindec('10101010001') is the syntax, and not a few bytes or something. That is not (yet?) implemented. I'm not sure this should be in PHP. PHP isn't meant to work with binary files. I think that usually there are better alternatives, for example if you're after saving a few bytes of diskspace, this isn't the way to go.