Comma-sparated items to array with PHP

Run Settings
LanguagePHP
Language Version
Run Command
<?php $a = 'journalist,press, media,news,'; function commaSparatedItems2Array($text) { return json_decode(str_replace(',""','', '["'. str_replace(',','","',$text) .'"]'), true); } print_r(commaSparatedItems2Array($a));
Editor Settings
Theme
Key bindings
Full width
Lines