Iam having this problem andi ill try to explain it the best i can. $query = mysql_query("SELECT * FROM $db[users_home_options] WHERE option_id = '$id'",$db[link]); $image = mysql_fetch_array($query); <form method="post" enctype="multipart/form-data" action="" > Select a Image Slot: <select name="slot"> <option value="image1" selected="selected">Slot 1</option> <option value="image2">Slot 2</option> <option value="image3">Slot 3</option> <option value="image4">Slot 4</option> <option value="image5">Slot 5</option> </select> <strong>Please Upload an Image of the Property</strong> <br /> Image of Property: <input type="file" name="userfile"> <br /> <input type="submit" name="Submit" value="Confirm & Save"> </form> $slot=$_POST[slot]; $filepath = "img/".$image[$slot]; if (! unlink ($filepath)) { echo ("Couldn't delete file"); } else { echo ("Removed $filepath"); } Code (markup): theres what i have so far, not to hard to follow, but i can't get the $image[$slot] to display, it won't retrieve the data, what am i doing wrong, i have tested $image[$slot] with other variables and it works. I left out alot of the code because it would seem alittle confusing on here. any help would be great thanks.