-
Hi, I am trying to adjust a file type upload. I need the ability to add .vcf files. I have tried the following on the fileupload.php page.
PHP12345678<code>$accepted_file_mime_types = array('image/gif','image/jpg','image/jpeg','image/png','application/pdf','application/zip','application/vnd.openxmlformats-officedocument.wordprocessingml.document','application/msword','text/plain','audio/wav','audio/mp3','audio/mp4','vcf' => 'application/octet-stream','vcf' => 'text/x-vcard');$file_extension = strtolower(strrchr($_FILES["userpro_file"]["name"], "."));if( !in_array($file_extension, array( '.gif','.jpg','.jpeg','.png','.pdf','.txt','.zip','.doc','.docx','.wav','.mp3','.mp4','.vcf' ) ) || !in_array($fileinfo,$accepted_file_mime_types) ){can you see what I am doing wrong? I get an error msg saying file type not allowed.
Thank You,
Viewing 1 post (of 1 total)
You must be logged in to reply to this topic.