<?php echo preg_replace('/(.*?)(\..*)$/', '$1-cxx-$2', '/foo/bar.jpg');
You have javascript disabled. You will not be able to edit any code.