Manage images - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived Libraries & Helpers (https://forum.codeigniter.com/forumdisplay.php?fid=22) +--- Thread: Manage images (/showthread.php?tid=41836) |
Manage images - El Forum - 05-18-2011 [eluser]Oleg Videnov[/eluser] Hello guys, I am new here and I am not exactly sure this is the right section,but just a simple question. I am trying to build simple CRUD admin control panel for creating users.The users have First Name,Last Name and image...no password,nothing else.just these three.The upload is going ok. I am storing the URL of the image in the database.And everything is displayed correctly. BUT when I want to edit the information-what should be the procedure for deleting the old image and uploading a new one. I am a bit confused how to do it.Just looking for simple solution.I am sure it exists,just don't know it. Thanks in advance ! Oleg Manage images - El Forum - 05-18-2011 [eluser]Toddish[/eluser] To delete an image, just use unlink($file). Then upload the new image as you initially did, storing the path/filename in the DB |