Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>The "magic" file used has nothing to do with Apache. It is used as <a href="http://en.wikipedia.org/wiki/Magic_number_%28programming%29" rel="nofollow">table of file signatures</a> and is, depending on your system, either a "magic" file distributed with PHP (<code>magic</code> or <code>magic.mime</code> in PHP's directory, most of the time), or the system's "magic" file (used by the <a href="http://linux.die.net/man/1/file" rel="nofollow"><code>file</code> command</a> on Unix).</p> <p>You can also ask to use a specific "magic" file like this:</p> <pre><code>&lt;?php $finfo = new finfo(FILEINFO_MIME, "/usr/share/misc/magic.mgc"); ?&gt; </code></pre> <p>You can either change the system's "magic" file or make your custom one. </p> <p>The <a href="http://www.garykessler.net/library/file_sigs.html" rel="nofollow">standard file signatures</a> for MPEG-4 audio and video are:</p> <pre><code>00 00 00 18 66 74 79 70 33 67 70 35 ....ftyp 3gp5 MP4 MPEG-4 video files 00 00 00 18 66 74 79 70 6D 70 34 32 ... ftyp mp42 M4V MPEG-4 video/QuickTime file 00 00 00 20 66 74 79 70 4D 34 41 20 ... ftyp M4A M4A Apple Lossless Audio Codec file </code></pre> <p>You may want to check first if these are in your "magic" file.</p> <p>From what I remember, m4a (audio) and m4v (video) may have the same mp4 signature (due to bad encoders), so you can't always differenciate one from the other using the "magic" file. You may then put some PHP code to determine, based on file extension (like Windows does), if it's video or audio mp4.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload