what is the regex for matching a string within two curly brackets as in
{{string}}
result should be string.
Do I have to escape both curly brackets?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
No, actually the following should work just fine:
Edit:
As pointed out by dtb the expression above fails for a string containing a single
}within the double brackets. To handle this case the following example would do a much better job:Edit 2: The simplest solution however would probably be the following: