I have a question regarding JSON. I am using a jquery plugin which expected JSON structure as below :
[ { key: "Id" },
{ key: "Username" },
{ key: "Age" }
],
but my JSON looks like :
[{
"Employee1":
{
"ID": 43036,
"Name": XYZ,
"Age": 21
},
"Employee2":
{
"ID": 30436,
"Name": MNP,
"Age": 23
}
}]
Now I don't want to change my code, is there any solution so that I can pass Id , Name to my plugin json without using "Employee". I need my JSON as :
[
{
"ID": 43036,
"Name": XYZ,
"Age": 21
},
{
"ID": 30436,
"Name": MNP,
"Age": 23
}
]
Thanks in Advance