if( move_uploaded_file($_FILES["imagefiles"]["tmp_name"],$path)){
header("location:index.php?file-inserted=ok&name=".$rename);
}
Get İle yakalarken de
if(isset($_GET["file-inserted"]==ok)){
echo 'eklendi
';
echo "Dosya İsmi:". $_GET["name"];
}