Welcome Guest, Not a member yet? Register   Sign In
.FLV file upload problem
#1

[eluser]Justin Patel[/eluser]
Hello friends,

I am trying to upload the flash file format, but it gives the error that this file format is not allowd.

please let me know, what can be the problem

Code:
$config['upload_path'] = './videos/';
                        $config['allowed_types'] = 'flv';
                        $config['max_size']    = '100000';
                        $config['max_width']  = '10000';
                        $config['max_height']  = '10000';
                        
                        $this->load->library('upload', $config);
                    
                        if ( ! $this->upload->do_upload())
                        {
                            $error = array('error' => $this->upload->display_errors());
                            print_r($error);
                        }    
                        else
                        {
                            $data = array('upload_data' => $this->upload->data());
                            print_r($data);
                        }
#2

[eluser]dawnerd[/eluser]
You need to add the flv mimetype to the mimes.php config file.

For example:
Code:
$mimes = array(
'hqx'=>'application/mac-binhex40',
'cpt'=>'application/mac-compactpro',
...
'flv'=>'video/x-flv'
);
Hope that helps you.
#3

[eluser]Justin Patel[/eluser]
[quote author="dawnerd" date="1200890423"]You need to add the flv mimetype to the mimes.php config file.

For example:
Code:
$mimes = array(
'hqx'=>'application/mac-binhex40',
'cpt'=>'application/mac-compactpro',
...
'flv'=>'video/x-flv'
);
Hope that helps you.[/quote]


Ohhh,

Thansk it works great ||||



Thanks for your help
#4

[eluser]Justin Patel[/eluser]
OPPS NEW PROBLEM,


IT WORKS FOR MY LOCAL HOST but not for the server

any help????????
#5

[eluser]dawnerd[/eluser]
Did you upload the modified mimes.php file? Does it give a different error than before?
#6

[eluser]Justin Patel[/eluser]
just the file you are trying to upload is not allowed
#7

[eluser]dawnerd[/eluser]
I would double check to make sure the mimes.php file is correct.
#8

[eluser]AlexC33[/eluser]
I add the same trouble.

corrected it by adding this line (in mimes.php) : 'flv' => 'application/octet-stream'

and it worked fine.
#9

[eluser]Zeeshan Rasool[/eluser]
guys , i have checked all these,but problem still going on. Tell me any other solu. thnx




Theme © iAndrew 2016 - Forum software by © MyBB