工作,我有一些代碼:
// Setup a content array for the tooltips
var Data = [];
var search = $("input#field_search").val();
var combo = $("select#search_option").val();
var jsonUrl = "ajax.php?module=formation&action=get_participant_list_json&filter_by="+combo+"&search="+search;
$.getJSON(jsonUrl, function(data) {
var items = [];
alert(data.join(" || ")); //WHAT TO SHOW YOU HERE
$.each(data, function(key, val) {
//alert(val);
items.push(val.replace(/@/gi,"#"));
});
//console.log(items);
//alert(items.join(" || "));
$(".tips").each(function(i){
$(this).simpletip({ content: items[i] });
});
});
如果我IE7
訪問照片直接:
ajax.php?module=formation&action=get_participant_list_json
或
ajax.php?module=formation&action=get_participant_list_json&filter_by=&search=
我收到了很好的回覆數據與秩序:
["0Bequart Claire","1AZZI Sarah"]
但我alert(data.join(" || "));
我有reseversed
0AZZI Sarah || 1Bequart Claire
DO喲知道我有什麼misstake?爲什麼要刷新響應列表的順序?
感謝您的幫助
您應該訪問完整的網址,該網址看起來就像是它的一半 – Alexander 2012-08-10 14:10:08
爲什麼?但我仍然有相同的如果ajax.php?module = formation&action = get_participant_list_json&filter_by =&search = – sophie 2012-08-10 14:11:28