PHP check file extension
<p>I have an upload script that I need to check the file extension, then run separate functions based on that file extension.  Does anybody know what code I should use?</p>

<pre><code>if (FILE EXTENSION == ???)
{
FUNCTION1
}
else if
{
FUNCTION2
}
</code></pre>
