i have modified my code
now i have the image file name , can i simply unlink the image from its folder
[b]
function delete_images($id)
{
$query=$this->db->get_where('add_images', array('id'=>$id));
foreach($query->result() as $row)
{
$file_name = $row->image; //image is tbl field that holds the image name
unlink( );
//what should i put inside the unlink function as i will delete the image from its folder
return TRUE;
}
$this->db->delete('add_images', array('id'=>$id)); // add_images is my table name
}
[/b]
