Let\'s say i have this json data. How to transform the \"tags\" to a string like
$tags = \"Rihanna, We, Found, Love, (Explicit), Def, Jam, Records, Pop\";
Try:
foreach($videosList as $i=>$video){ $videosDatas['videos'][$i]['title'] = $video->title; $tags = implode(', ',$video->tags); $videosDatas['videos'][$i]['tags'] = $tags; }
In place of your code:
for($i=0; $i