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.
2. On this topic: Note that the php file that I changed to jpg could not execute as is of course....so to all who are wondering it's still a safe class!!!
3. However, I believe, if I'm using the class correctly?, then there should be TWO checks for the mime type to validate the file before it get's moved to the public directory. A) The current initial check which seems to be received from the browser and then a second check when the file reaches the phptemp directory....
4. Oh one other minor thing
$handle->file_overwrite = TRUE;
When I tell it to overwrite the file it doesn't it keeps appending with _NN
2. The image will be executable depending on the server configuration. Generally, the picture will not be executed through PHP, and will be served as an image.
3. I will check all of that, and post the results here.
4. You also need to deactivate file_auto_rename, as following:
2. On this topic:
Note that the php file that I changed to jpg could not execute as is of course....so to all who are wondering it's still a safe class!!!
3. However, I believe, if I'm using the class correctly?, then there should be TWO checks for the mime type to validate the file before it get's moved to the public directory.
A) The current initial check which seems to be received from the browser and then a second check when the file reaches the phptemp directory....
4. Oh one other minor thing
When I tell it to overwrite the file it doesn't it keeps appending with _NN
Anyway...Love this class !!!
2. The image will be executable depending on the server configuration. Generally, the picture will not be executed through PHP, and will be served as an image.
3. I will check all of that, and post the results here.
4. You also need to deactivate file_auto_rename, as following: