I'm trying to extend PHP Markdown to allow the use of {{ and }} around some parts of the text (they will become search keywords, like a tag).
I have this basic regex that kinda works:
preg_match_all("/\{\{(.*)\}\}/", $description, $nomsTags);
Except it doesn't work when there are 2 keywords in the same sentence:
This {{is}} just an {{example}}.
It returns '{{is}} just an {{example}}
' instead of '{{is}}
' and '{{example}}
'.
How can I modify the regex so it works in both cases?