本文整理汇总了C#中CmsData.CMSDataContext.OptOuts方法的典型用法代码示例。如果您正苦于以下问题:C# CMSDataContext.OptOuts方法的具体用法?C# CMSDataContext.OptOuts怎么用?C# CMSDataContext.OptOuts使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类CmsData.CMSDataContext
的用法示例。
在下文中一共展示了CMSDataContext.OptOuts方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: EmailReplacements
public EmailReplacements(CMSDataContext callingContext, string text, MailAddress from, int? queueid = null)
{
currentOrgId = callingContext.CurrentOrgId;
connStr = callingContext.ConnectionString;
host = callingContext.Host;
db = callingContext;
this.from = from;
if(queueid > 0)
OptOuts = db.OptOuts(queueid, from.Address).ToList();
if (text == null)
text = "(no content)";
var pattern =
[email protected]"(<style.*?</style>|{{[^}}]*?}}|{RegisterLinkRe}|{RegisterTagRe}|{RsvpLinkRe}|{RegisterHrefRe}|
{SendLinkRe}|{SupportLinkRe}|{MasterLinkRe}|{VolReqLinkRe}|{VolReqLinkRe}|{VolSubLinkRe}|{VoteLinkRe})";
// we do the InsertDrafts replacement code here so that it is only inserted once before the replacements
// and so that there can be replacement codes in the draft itself and they will get replaced.
text = DoInsertDrafts(text);
text = MapUrlEncodedReplacementCodes(text, new[] { "emailhref" });
try
{
var result = PreMailer.Net.PreMailer.MoveCssInline(text);
text = result.Html;
}
catch
{
// ignore Premailer exceptions
}
stringlist = Regex.Split(text, pattern, RegexOptions.IgnoreCase | RegexOptions.Singleline | RegexOptions.IgnorePatternWhitespace);
}