<?php $input = <<<STR <p>{{ myFunction() }}</p> <p> </p> <p>{{ number|number_format(2, " . ", ' , ') }}</p> <p>{% set myVariable = ' ' %}</p> STR; echo preg_replace('/ (?=(?:(?!{[{%]).)*[%}]})/', ' ', $input);
You have javascript disabled. You will not be able to edit any code.