I wonder how i can exclude a substring from the result after it matches the pattern. example:
<a href="?page1"><?php __('string1');?></a>
<a href="?page2"><?php __("string2");?></a>
I want to get only the strings passed as parameters to the __() function. i tried this regex:
'/__\(((\'([^\']+)\')|(\"([^\"]+)\"))/'
but that returns 'string1' and "string2" wrapped in single quotes and double quotations.
how can i exclude single quotes and double quotations?