Q:

ajax post return the html

I have this ajax function (refer below)
$.ajax({
    url: "processor.php",
    type:"POST",
    data: { 'id' : "itemid, 'itemname' : itemname, 'itemdesc' : itemdesc" } ,
    success:function(e){
        if(($.trim(e) == "success")){
            alert("success");
        }else{
            alert(e);
        }  
    },error:function(){
        alert("critical error");
    }
});

assume that I already have the linked script of jquery and the content of those variables that has been declared on the data argument inside ajax function. Now I have a processor.php (refer below)
//this is the processor php
echo "success";

so base from above references, the ajax function submit a post request to processor.php and then the processor.php will respond "success" string as declared with the "echo success" but what happen is it doesn't get the success response instead the whole html tags on the current page is pop up (alert), why?? any ideas, clues, recommendation, suggestion would be greatly appreciated. Thank you.
PS: i know the response is not success but why it popup (alert) the whole html tags in the current page?

A:

I've been experienced that before, check your folder and file structure and if you're running server side script (such as php) or communicating with database, check your virtual host configuration.

