Convert file to binary string with PHP -


I am looking to convert a file into a binary string, using priority PHP. Is this possible?

More information: Users want to upload a small file through a form, and return the binary representation of that file as a binary string - i.

  $ str = 'hello world'; $ Length = stellon ($ str); $ Result = ''; ($ I = 0; $ i & lt; $ length; $ i ++) {$ Result = Str_pad (debabin (ord ($ str [$ i])), 8, '0', STR_PAD_LEFT); } Return results $;    

Comments