Why the following upload if condition does not work?
<p>So I have an upload script, and I want to check the file type that is being uploaded. I only want pdf, doc, docx and text files</p>

<p>So I have:</p>

<pre><code>$goodExtensions = array('.doc','.docx','.txt','.pdf', '.PDF');
$name = $_FILES['uploadFile']['name'];
$extension = substr($name, strpos($name,'.'), strlen($name)-1);


 if(!in_array($extension,$goodExtensions) || (($_FILES['uploadFile']['type'] != "applicatioin/msword") || ($_FILES['uploadFile']['type'] != "application/pdf"))){
     $error['uploadFile'] = "File not allowed. Only .doc, .docx, .txt and pdf";
 }
</code></pre>

<p>Why I'm getting the error when testing and including correct documents?</p>
