







[Missing <summary> documentation for "T:Symplus.Core.Net.EmailTemplateParser"]
Namespace: Symplus.Core.Net
Assembly: Symplus.Core (in Symplus.Core.dll) Version: 1.1.7.1510 (1.1.7.1510)
Syntax
C# |
---|
public class EmailTemplateParser |
Visual Basic |
---|
Public Class EmailTemplateParser |
Visual C++ |
---|
public ref class EmailTemplateParser |
Remarks
Template Parser is simple parser has been written on C#.
It allows setup variables and conditions block in template.
Also you can use some of variable's modificators.
Author: Alexander Kleshevnikov
E-mail: [email protected]
Examples
There is the simpl example of template for html page:
To parse this template you can use the following code:
![]() | |
---|---|
<html><head><title>##Title##</title></head><body><h1>##Title:upper##</h1> ##If--IsRegisteredUser## Hello, ##UserName##! ##Else--IsRegisteredUser## Please sign in. ##EndIf--IsRegisteredUser## </body></html> |
![]() | |
---|---|
... Hashtable Variables = new Hashtable(); Variables.Add("Title", "Login In"); Variables.Add("IsRegisteredUser", true); Variables.Add("UserName", "seigo"); TemplateParser tpl = new TemplateParser("template.htm", Variables); tpl.ParseToFile("result.htm"); ... |