Access json value using JavaScript object notation

后端 未结 4 806
囚心锁ツ
囚心锁ツ 2021-01-28 18:34

I am unable to access a json value

{\"phone\": [
{
    \"@attributes\": {
        \"type\": \"cell\",
        \"ext\": \"\"
    }
}, \"(123) 456 7890\", {
    \"         


        
4条回答
  •  面向向阳花
    2021-01-28 19:05

    since phone is an array, try this,

       for(var i=0;i

    Also surround your response with {, as it is currently an invalid json.

提交回复
热议问题