开发者

jQuery .AJAX is not moving on to the SUCCESS and alerting

See anything wrong with this?

$.开发者_运维问答ajax({
    url: '/nav/side',
    data: "urlpath=" + urlpath,
    success: function(data) {
        alert('Load was performed.');
      }
});

For some reason it's not alerting.. I'm using rails 3...

Thanks


There's something outside of your question that's erroring, check your console for errors. For actual request debugging, add an error handler so you can see what's blowing up, like this:

$.ajax({
    url: '/nav/side',
    data: "urlpath=" + urlpath,
    success: function(data) {
        alert('Load was performed.');
    },
    error: function(xhr, status, error) {
        alert('An error occured: ' + status + '\n' + error);
    }
});
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜