阿贾克斯上服务器灯

I have this code:

$.ajax({
           type: "POST",
           url: url,
           data: form.serialize(), // Send the form information as 
           success: function(data) {
                var data_succ = data;
                alert(data_succ);
                if(data_succ=="0"){ window.location.href = "problem.php"; }
                if(data_succ=="2") {window.location.href = "summary.php";}
                if(data_succ=="3") {window.location.href = "res.php";}
                $.get('removefile.php');
                return false;
           },
           error: function() {
                window.location.href = "swrong.php";
                return false;
           }
    }); 
  });


in localhost everything works fine. However, on a lamp server works everything but not

$.get('removefile.php');

I also tried to put all the path to the file, /var/www/html/folderproject/removefile.php, but it didn't worked.