This is a bit of a reverse engineering question, but I want to know how to write in PHP a proper multidimensional array in PHP that outputs the following javascript array.
[
{
"key": "Basic Planners",
"values": [{"x": "YourPhone","y": 150},
{"x": "Universe X3","y": 300},
{"x": "ePhone 74s","y": 1500},
{"x": "NextUs","y": 50},
{"x": "Humanoid","y": 500
}]
}, {
"key": "No-Namers",
"values": [{"x": "YourPhone","y": 300},
{"x": "Universe X3","y": 250},
{"x": "ePhone 74s","y": 400},
{"x": "NextUs","y": 150},
{"x": "Humanoid","y": 900}]
}, {
"key": "Feature Followers",
"values": [{"x": "YourPhone","y": 350},
{"x": "Universe X3","y": 900},
{"x": "ePhone 74s","y": 100},
{"x": "NextUs","y": 500},
{"x": "Humanoid","y": 250}]
}, {
"key": "Hipsters & Elites",
"values": [{"x": "YourPhone","y": 200},
{"x": "Universe X3","y": 350},
{"x": "ePhone 74s","y": 50},
{"x": "NextUs","y": 800},
{"x": "Humanoid","y": 100}]
}
]
{"Basic Planners": [{"x":...},...], "Feature Followers":[...]etc