What is PHP for C # (as we open some local files on the server (instead of OpenFileDialog)
Private const int HEADER_LENGTH = 13; stream = file.OpenRed (OpenFileDialog.filname); Header = ReadBase (stream, HEADER_LENGTH);
It will be able to do this in PHP as the next step
Private cost byte sign 1 = 0x46; Private cost byte signature 2 = 0x4C; Private cost byte signature 3 = 0x56; if ((Sign = = Header [0]) | (Signature 2! = Header [1]) || (Signature 3! = Header [2]) Throw new invalid data exception ("Not valid FLV file ! ");
Hmm, I think you find something like this < / P> Definitely y can create constants for this signature, but like this: Then you can use them as normal:
define ('SIG1', chr (0x46));
$ head [0] == SIG1
etc. When defining a constant constant, for both fixed name and value.
Comments
Post a Comment