title: Codeigniter putting underscore when overwrite is true in upload method
body: <pre><code>$config['file_name'] = $logged_in_user['user_name'].".png";
                      $config['upload_path'] = 'assets/profiles/';
                      $config['allowed_types'] = 'gif|jpg|png';
                      $config['overwrite'] = true;
  
                      $this-&gt;load-&gt;library('upload', $config);
                      if ($this-&gt;upload-&gt;do_upload("picture")) {
  
                          print_r($this-&gt;upload-&gt;data());
                          $upload_data = $this-&gt;upload-&gt;data();
  </code></pre>
  
  <p>}</p>
  
  <p>When i am running this function i have already a file <code>abc.png</code> in my directory. As the upload methods runs, it  is saving a file with abc_.png Why it is appending underscore? I read in other post here that this could be because of spaces. But i dont think there is any space in  <code>$config['file_name'] = $logged_in_user['user_name'].".png";</code></p>
  
  <p>Please note that the already existed abc.png is pure PNG image while the file i am uploading is actually a jpeg image which i concatenate with .png just to make the file name same. I will do image conversion later after fixing this issue.</p>
  
  <p>Thanks</p>