class.upload.php is a powerful and mature PHP class to manage uploaded files, and manipulate images in many ways. The script is available under a GPL license.
I'm trying to allow HTML files to be uploaded, and I've added a check to ensure that only HTML files are uploaded.
But every time I upload one, it is getting the .txt extension added. I've tried setting no_script to false, but when I do this I then get an 'Incorrect file type' error for any file that I try to upload.
But every time I upload one, it is getting the .txt extension added. I've tried setting no_script to false, but when I do this I then get an 'Incorrect file type' error for any file that I try to upload.
Here's the code;