how implode will works in php code example
Example 1: php implode
$colors = array("red","blue","green");
$colorsCSV= "'".implode("','",$colors)."'";
//$colorsCSV: 'red','blue','green'
Example 2: php implode in html tags
$value = "<span>".implode('</span>,<span>', $values)."</span>";