• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
File upload file_name not returning any values

PHP Code:
$config['upload_path'] = 'uploads/file/';
$config['allowed_types'] = 'xlsx|pdf|txt';
$config['max_size'] = '5000';
$file $this->upload->data();
$file_name $file['file_name']; 

Everything is working fine and my uploaded file can move to it's path but i want to know why this code is not working.It is also indicated in the user guide. Even the all of the data from the uploaded file returns no value(like raw_name, file_ext). I searched all over the web and i can't find any answers to my problem.
I'm using Wampserver 2.5. Php 5.5.12.

The code you've provided is missing a call to $this->upload->do_upload('fieldname')

Thanks! finally it worked! +1

Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  

  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2020 MyBB Group.