• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
The upload path does not appear to be valid ???????

Hi every one,
I am having this problem in uploading image and seriously making my hairs out. I have googled and gone thorough many forums but could not solved this out.

Here is the code for uploading image
function do_upload()
  // echo "there is directory <br/>";
  else echo "<br>there is no directory</br>";
  $config['upload_path'] ='./uploads/';
  $config['allowed_types'] = 'gif|jpg|png';
  $this->load->library('upload', $config);
  if (!$this->upload->do_upload())
  // echo "<br/>noupload<br/>";
   $error = array('error' => $this->upload->display_errors());
   //echo "<br/>yesupload";
   $data = array('upload_data' => $this->upload->data($userfile));
   $image_path = $data['upload_data']['file_name'];
   return $image_path;

But it shows the error The upload path does not appear to be valid. I have gone through the forums and it said to add


but whenever i add that code nothing happens even doesn't display any errors.

Please help me out of this. Thanks in advance

Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  

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