Answers for "get values from comma separated string in php"

PHP
4

array to string separated by comma php

$arr = array ( 0 => "lorem", 1 => "ipsum", 2 => "dolor");

$str = implode (", ", $arr);
Posted by: Guest on September-22-2020
1

convert comma separated number to number in php

$number = '1,000.5669';
$number = (float) str_replace(',', '', $number);
var_dump($number);
Posted by: Guest on June-15-2021

Code answers related to "get values from comma separated string in php"

Browse Popular Code Answers by Language