I have the following PHP array:
array("Apple", "Pear", "Grape", "Orange")
And I'd like to get JSON output like the following:
[[{"fruit":"Apple"}],[{"fruit":"Pear"}],[{"fruit":"Grape"}],[{"fruit":"Orange"}]]
JSON confuses me :(
EDIT Sorry, those last two in the output should have been fruit, I corrected it, sorry guys.
fruits and which arelabels?fruitandlabel.