If you have more then one folder that is used for holding images, when you insert that name of the image into the form, if you include the accompanying folder, it will work properly.
Example: 'images_one/image1.jpg'
However if you don't know what folder that image is being housed in, or if you want to delete all instances of an image in all folders, you could write a function that checks for the image name in each folder, and if found deletes it that way. I hope that atleast gets you started.
Hope it helps,
php_dev