我的一个函数返回以下字符串:
{
"data": [{
"type": "facebook",
"id": "639422616",
"name": "Neal Cabage",
"message": "Ruby on rails or Sinatra better for a restful app that speaks json, not html?"
}, {
"type": "facebook",
"id": "100001604824773",
"name": "Christolle Soragee",
"message": "When you lose: "
Who cares ? !It 's just a game!" When you win: "HAHAHA IN YOUR FACE LOSER!""},{"type":"facebook","id":"100000049925091","name":"Chris Cassanova Dunphy","message":"It'
s sad when you already know you 're gonna get ripped off and you have to junkie proof your stash... Hahaha good thing I was on point! It'
s funny how people with a problem will ruin a good thing just "}]}
当我使用jQuery.parseJSON(response)
时,在某些情况下,当消息在消息中包含双引号时,它会引发异常。
任何帮助或建议将不胜感激。
谢谢