代码: new Ajax.Request(’/your_url’), { method : ‘get’, onSuccess : function(transport){ var response = transport.responseText || “no response text”; alert(”Success!”); } , onFailure : function(){ alert(’failure’)} });