IM有一些問題outting我返回數組 - 在控制檯登錄它顯示了使用的jQuery/JSON輸出數據
{
"text":"{\"error\":false,\"msg\":\"found in search\"}",
"data":{
"notifications":[
]
}
}
IM
success : function(data){
$('#waiting').hide(500);
$('#message').removeClass().addClass((data.error === true) ? 'error' : 'success').text(data.msg).show(500);
if (data.error === true)
$('#restricted_locator').show(500);
},
然而data.msg返回undefined,但現在看數組它沒有任何提取,但我怎麼能改變從文本中獲取數據?
在此先感謝!
如果它顯示了這個日誌輸出,當你登錄的數據,然後只是嘗試data.text – kiev
data.text顯示數據的數組,但我需要獲得數組內的數據 - 輸出時,當我使用,這是我所作的以上 –
對不起,當我的控制檯數據我得到上述 –