Hi, recently I have been working on a file upload script that users can upload an image. I got it to work but I am stuck on how to let user update or change the image they upload.
I would like this to work kind of like facebook photos work. Any feedback would be helpful.
For changing image follow below steps:
- one php page where user see his/her old uploaded image with browse button.
- when user upload image with browse andf click on update button, on server side in php code check if image is valid.
- if all is set then firstly unlink (delete) old image and upload new image in folder location and use 'update' sql query to update image name in database.