- implode: documentation ( source)
<?php
$someArray = [];
$someArray[] = "one";
$someArray[] = "two";
$someArray[] = "three";
$someArray[] = "four";
$anotherArray = [];
$anotherArray[] = ",";
$anotherArray[] = ":";
$anotherArray[] = "/";
$anotherArray[] = "-";
echo(implode($someArray, ','));
echo "\n";
echo(implode(',', $someArray));
echo "\n";
echo(implode($someArray, $anotherArray));
echo "\n";
echo(implode($anotherArray, $someArray));