The $group variable contains an array in which to output the last line without a comma. I do it like this:
$group = '{"title":"Title", "artist":"Artist", "cover":"img/1.png", "file":"./file/1.mp3"},'; $numItems = count($group); $i=0; foreach($group as $filter) { if(++$i === $numItems) echo $group; else echo $group','; } does not work. How correct?
$numItems-1do - Lex Hobbit