Answers for "php key value array to string"

PHP
0

php array to string

// for one-dimentional arrays
$str = implode('|', $arr);	// "v1|v2|v3"...

// for multi-dimensional/structured arrays, or to keep hierarchy
$str = json_encode($arr);
// or
$str = var_export($arr);
Posted by: Guest on February-17-2021
1

php key value array to string

$requestAsString = print_r($_REQUEST, true);
Posted by: Guest on September-22-2021

Browse Popular Code Answers by Language