Answers for "regex get text between braces"

PHP
0

regex get text between braces

$text = 'ignore everything except this {{ text1  }}';
preg_match('#\{\{(.*?)\}\}#', $text, $match);
var_dump($match);
Posted by: Guest on August-10-2020

Code answers related to "regex get text between braces"

Browse Popular Code Answers by Language