开发者

How do I get a JSON field with the name part#

开发者 https://www.devze.com 2023-02-18 01:53 出处:网络
The title really sums it up, when I try to access the field, I get a parse error in javascript var data = JSON.parse(xhr.responseText开发者_Go百科).features

The title really sums it up, when I try to access the field, I get a parse error in javascript

var data = JSON.parse(xhr.responseText开发者_Go百科).features
for (var x in data) {
   var o = data[x];
   Ti.API.info("part number" + o.part#);
}


Use square bracket notation to access properties with names that include characters not allowed in an identifier.

o['part#']
0

精彩评论

暂无评论...
验证码 换一张
取 消