managed to redirect to editdata.php if no file is uploaded.