jQuery テンプレート タグを見つけるための C# 正規表現を探しています。ユーザーが独自の文字をデザインできるエディターがあり、それらのタグを実際の値に置き換える必要があります。
次に例を示します。
Welcome {{Name}} to our webshop. Your last visited our website on {{LastVisit}}
サーバー上で、投稿されたコンテンツでこれらのタグを検索したいと思います。次のようなものです。
[HttpPost]
public ActionResult Create(Report report)
{
    Dictionary<string,string> tags = new Dictionary<string,string>();
    var matches = Regex.Matches(report.Content, @"\{{2}(?'tagname'[^{}]+)\}{2}"); 
    foreach(Match match in matches){
      tags.add(match.Value, match.Groups[1].Value);
    }
    return View();
}
私の正規表現はこれを返すはずです:
- 名前
 - 最後の訪問
 
あなたが私を助けてくれることを願っています!