Wednesday, June 5, 2024
 Popular · Latest · Hot · Upcoming
139
rated 0 times [  141] [ 2]  / answers: 1 / hits: 31191  / 13 Years ago, mon, november 21, 2011, 12:00:00

Json Array as following is easy to parse,



{
movieCategories: [
a : Animation,
b :Romance,
c :Science Fiction
d : Western
]
}


Now,I have a Json response as following which is stored in movies.json file.



{
movieCategories: [
Animation,
Romance,
Science Fiction,
Western
]
}


I am not sure how to parse the above json array. Kindly help.



Thank you.


More From » json

 Answers
26

Assume



    var test = {
movieCategories: [
Animation,
Romance,
Science Fiction
Western
]
}


then



test.movieCategories[0] // Will be Animation

[#88986] Saturday, November 19, 2011, 13 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
emileef

Total Points: 724
Total Questions: 108
Total Answers: 102

Location: Romania
Member since Sun, Dec 20, 2020
4 Years ago
;