删除json编码数组中的多个引号

时间:2015-02-07 12:52:33

标签: php ajax json wordpress

是否可以从json编码的数组中删除双引号? 例如:

{"96":{"term_id":96,"name":"AS Roma","slug":"as-roma","term_group":0,"term_taxonomy_id":100,"taxonomy":"klient","description":"HWDP","parent":0,"count":5,"object_id":1800,"filter":"raw"},"100":{"term_id":100,"name":"Atletico Madrid","slug":"atletico-madrid","term_group":0,"term_taxonomy_id":104,"taxonomy":"klient","description":""vamos amigos"","parent":0,"count":6,"object_id":1800,"filter":"raw"}}

这是来自wordpress get_the_terms函数的值数组。正如您可能会看到其中一个值"描述":"" vamos amigos""双引号加倍(描述中的输入文本在引号内)。这给了我一个关于ajax响应的错误。我已经尝试过删除这双引号的所有内容 - 没有什么对我有用吗? 我很感激任何迹象。

0 个答案:

没有答案