What's the easiest way to find out the filetype of a URL that's stored within a variable?
I'm looking to write something that will I want to do this:
$url = http://site.com/flash.swf
if $url contains .swf, <embed flash>
else if $url contains .gif, <img src>
else if $url contains .zip, <display url>
Thanks. 🙂