i have this Json:
"AMAZ": {
"LOAS": {
"1": "NAME1",
"2": "NAME2"
},
"BAG": {
"ASLO": {
"1": "NAME1",
"2": "NAME2"
}
im trying to get the NAME1 and NAME2 text.
I tried with:
var json = $.parseJSON($("#json").val());
var test = json.AMAZ.LOAS.'1';
alert(test);
but i get an error here:
var test = json.AMAZ.LOAS.'1';
i get Unexpected string '1'
How can i get the values?
json.AMAZ.LOAS[1]