<?php $text = 'binary_function([x,y]) and binary_function([x1,y1,z1])'; echo preg_replace_callback('~binary_function\(\[(.*?)]\)~', function ($m) { return implode("", array_map(function ($x) { return strtoupper($x); }, explode(",", $m[1]))); }, $text);
You have javascript disabled. You will not be able to edit any code.