Remove element from multidimensional array

后端 未结 6 1729
情歌与酒
情歌与酒 2021-01-13 06:10

I have following multidimensional array:

{\"2\":{\"cid\":\"2\",\"uid\":\"2\"},\"1\":{\"cid\":\"1\",\"uid\":\"3\"}}

In this example i want t

6条回答
  •  广开言路
    2021-01-13 07:01

    JavaScript doesn't have multi dimensional Arrays, only arrays and objects. That said: delete theObject['1']; should work just fine

提交回复
热议问题