Hello i have this lex parser template which contains a callback tag which i want to be removed because i get an infinite loop.
I tried with php preg_replace
but then i get a white screen. The tag that i want to remove is in this format:
{{ search:query term="value" .. more attributes .. }}
// any content between these tags needs to be removed as well, including new lines
{{ /search:query }}
And this is my try at preg_replace:
$text = preg_replace('@\{\{\ssearch:(.*?)\}\}(.*?)\{\{\s/search:(.*?)\s\}\}@is','',$text);
But it doesn't work. Any advice why?
Handles missing and multiple whitespace, one or more
attr="value"
pairs, multi-line and is non-greedy.