Welcome Guest, Not a member yet? Register   Sign In
File upload what am i missing???
#1

[eluser]123wesweat[/eluser]
Code:
if (isset($_FILES['user_file']['size']) && count($_FILES))
                    {
                    
                    echo $_FILES['user_file']['size'];
                    //die();
                      // Config, etc
                    $config['upload_path'] = base_url().'avatars/';
                    echo $config['upload_path'];
                    $config['allowed_types'] = 'gif|jpg|png';
                    //$config['max_size']    = '10000';
                    $config['max_width']  = '1024';
                    $config['max_height']  = '768';
                    $this->load->library('upload', $config);
                    $this->upload->do_upload();
}
all echos as expected but the file isn't uploaded. I chmod the folder 777.

Any advice
#2

[eluser]123wesweat[/eluser]
ok found it i had $user_file and not $userfile;




Theme © iAndrew 2016 - Forum software by © MyBB