Jump to content

using IF with multiple results?


joecooper

Recommended Posts

[!--quoteo(post=366101:date=Apr 18 2006, 12:58 PM:name=joecooper)--][div class=\'quotetop\']QUOTE(joecooper @ Apr 18 2006, 12:58 PM) [snapback]366101[/snapback][/div][div class=\'quotemain\'][!--quotec--]
if ($_FILES['userfile']['type'] == 'wmv' or 'mpg' or 'mpeg' or 'avi'){

how can i make that work? Thanks
[/quote]

Something like:

if ($_FILES['userfile']['type'] == 'video/x-ms-wmv ' || $_FILES['userfile']['type'] == 'video/mpeg' || $_FILES['userfile']['type'] == 'video/x-msvideo'){

video/mpeg will handle MPG and MPEG.
video/x-msvideo will handle AVI
video/x-ms-wmv will handle WMV (not sure about this one)

I'm not positive on the WMV one, but it may be right. You need to know the mime types associated with the files you are comparing against.
Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.