I am creating a video site on CodeIgniter (v 2.1.0). Administrators can upload videos through the admin panel. It works fine on my local server. But it does not work on the remote test server. I installed mimes.php to correctly recognize the file type. Allowed file types are fine. But the error message states that the file type is not allowed. Here is my mimes.php:
... 'mp4' => 'video/mp4', 'flv' => 'video/x-flv', 'avi' => 'video/x-msvideo', 'mpeg' => 'video/mpeg', ...
Activated file types:
$upload_config['allowed_types'] = 'flv|mp4|avi|mpeg'
Library loading is initialized with $this->upload->initialize($upload_config);
If I do var_dump for $ _FILES, this gives me:
array(1) { ["video_file"]=> array(5) { ["name"]=> string(48) "test_video_file.mp4" ["type"]=> string(9) "video/mp4" ["tmp_name"]=> string(14) "/tmp/phpwkOICI" ["error"]=> int(0) ["size"]=> int(5668643) } }
What's bad about it? What turns me on is that the same script works fine on my local machine, but doesn't work on a remote test subdomain. And every debug message looks legal to me. Any help is much appreciated. Thank you and welcome
source share