Welcome Guest, Not a member yet? Register   Sign In
How do I delete a single file?

Hey guys.

I've just recently started to learn CodeIgniter and have just begun playing with the file uploading class. I've been looking around a bit for how I can delete a single file which has been uploaded but all I've found is the function
which deletes all files in a directory..

So, how should I delete a single file?

regular php?


Yeah don't be afraid to use regular PHP Smile

Unlink() is the the one you need...but remember you have to give unlink() an absolute path to the file not a URL or you could have people remotely deleting files via HTTP!

Theme © iAndrew 2016 - Forum software by © MyBB