I have a 2 MB JSON object that I'm hoping to parse with jQuery. I dumped the whole object into a file named "timeline.js" and I'm hoping to parse through it as a dataset to grab records as needed.
My dataset started as an XML file, but I read that JSON would be more efficient as I'm using jQuery to pull the data and place it in the DOM.
Below is the first record of my object. How would I parse this object to grab the record with a 'profileid' of 1016?
{
timeline:{
record:[
{
profileid:1016,
title:'Adam',
parentprofileid:0,
type:'Person',
minzoomlevel:29,
maxzoomlevel:66,
isapproxstart:1,
isapproxend:1,
startdate:-4181,
enddate:-3251,
shortdescription:'Name means "red" or "man" he is...',
article:'<div><span>The first member of...',
status:22,
scriptures:{
scripture:[
{
profileid:1016,
scripturetext:'Genesis 2:7',
referencetext:'Birth'
},
{
profileid:1016,
scripturetext:'Genesis 5:4',
referencetext:'Death'
}
]
}
},