Answers for "how to implode in php"

PHP
5

php implode array

$values = array_map('array_pop', $array);
$imploded = implode(',', $values);
Posted by: Guest on March-03-2020
6

php implode

$colors = array("red","blue","green");
$colorsCSV= "'".implode("','",$colors)."'";
//$colorsCSV: 'red','blue','green'
Posted by: Guest on November-27-2019
0

php glue strings

<?php
$a = "Hello ";
$b = $a . "World!"; // now $b contains "Hello World!"

$a = "Hello ";
$a .= "World!";     // now $a contains "Hello World!"
?>
Posted by: Guest on August-03-2020

Browse Popular Code Answers by Language