开发者

Two call two pages in ajax in a single call using jquery?

My code calls ajax of single page and fetch result from that...

    ajax_data='ajax_mode=yes&data_id='+data1;
    $.ajax({
       type: "POST",
       url: "sample.php",
       data: ajax_data,
       dataType: "html",
       success: function(msg){
        alert(msg);
       }
    });

Question: I need to call multiple ajax pages in a single call (i.e开发者_Go百科 within $.ajax) and fetch result of appropriate pages


Redesign your server side processes to return two sets of data, organized in a way that you can separate them out easily (e.g. by presenting the data as JSON).

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜