Giusto per scrupolo, invece di
if ($_FILES["file"]["error"] > 0){

prova un attimo a mettere
if ($_FILES["file"]["error"] != 0){