Hello,
I'm trying to wrap a JSON array inside a JSON object but cannot figure out how.
Here's the tutorial I'm following:
In this example, you send a JSON array inside a JSON object's "data" field. Each item should have a field called "text".
{"data": [{"text": "I love Titanic."},
{"text": "I hate Titanic."}]}
This is my JSON array (var_dumped)
string '["data",{"text":"Wrapped in my blanket always makes me feel a little better when I'm not feeling to well"},{"text":"@sportsology I know they are still far apart but I'm definitely feeling better"},{"text":"The way I'm feeling right now <<<<<"},{"text":"Sometimes my dad will sense when I'm feeling a bit shit and just give me a hug and it always makes me feel better. #appreciationtweet"},{"text":"@HayliMarie3 o no!!!!! I'm just now feeling better today!!! Suck down those emergencies!!!"},{"text'... (length=1005)
This is my JSON object (var_dumped)
string '"data"' (length=6)
How can I go about this?