3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php function array2CSVarray(array $array) { $sanitized = array(); foreach ($array as $col) { $col = str_replace(array('\\', '"'), array('\/', '\"')); $sanitized[] = "\"$col\""; } return implode(',', $sanitized); }
Output for 5.3.6 - 7.2.0