I often use this piece of code in PHP
$ordine[\'address\'] = implode(\', \', array_filter(array($cliente[\'cap\'], $cliente[\'citta\'], $cliente[\'provincia\'
Why so serious? Try StringUtils.join(new String[] {"Hello", "World", "!"}, ", ") !
StringUtils.join(new String[] {"Hello", "World", "!"}, ", ")