PHP File Upload Class
fileupload.class extends PHP's native support for uploading image and text files through a Web browser. It can clean up the file's name, detect its mime type, and add the proper extension. Special characters in the file's name get deleted and spaces get replaced with underscores. The new "cleaned up" name is then returned by the class for use with a database or link management. There is also the ability to add your own mime-types and corresponding extensions. Other customizable variables include the path to the directory where files will be uploaded, maximum file size, maximum image width, maximum image height, acceptable file types, and whether or not uploaded files can be overwritten.