Welcome Guest, Not a member yet? Register   Sign In
Little problem with new file name function
#2

[eluser]CroNiX[/eluser]
Because of this:
Code:
$url = base_url($this->upload_dir . '/' . $file);
        
$uri = $url . '.' . $ext;
if(file_exists($uri))

Code:
$uri now = http://yoursite.com/some_dir/the_file.ext

It should be a filepath
Code:
/the/file/path/to/the_file.ext
, not the full url. It's a file on the filesystem, not a web resource.

PHP Manual: file_exists()


Messages In This Thread
Little problem with new file name function - by El Forum - 01-19-2014, 05:15 AM
Little problem with new file name function - by El Forum - 01-19-2014, 12:12 PM
Little problem with new file name function - by El Forum - 01-19-2014, 02:42 PM



Theme © iAndrew 2016 - Forum software by © MyBB