public int CreateTriggeredSendDefinitionWithEmailTemplate(string externalKey, string layoutHtmlAboveBodyTag, string layoutHtmlBelowBodyTag) { return(CreateWithTemplate(externalKey, layoutHtmlAboveBodyTag + "<body>" + EmailContentHelper.GetContentAreaTag("dynamicArea") + EmailContentHelper.GetOpenTrackingTag() + EmailContentHelper.GetCompanyPhysicalMailingAddressTags() + "</body>" + layoutHtmlBelowBodyTag)); }
public int Create(string externalKey) { return(CreateWithTemplate(externalKey, "<html>" + "<body>" + EmailContentHelper.GetContentAreaTag("dynamicArea") + EmailContentHelper.GetOpenTrackingTag() + EmailContentHelper.GetCompanyPhysicalMailingAddressTags() + "</body>" + "</html>")); }
/// <summary> /// <para>Creates a Triggered Send Definition with an email template containing a content area. (and %%Subject%% replacement value)</para> /// <para>You can specify html layouts for above and below the body tags.</para> /// </summary> /// <param name="externalKey"></param> /// <param name="layoutHtmlAboveBodyTag"></param> /// <param name="layoutHtmlBelowBodyTag"></param> /// <param name="priority"></param> /// <returns></returns> public int CreateTriggeredSendDefinitionWithEmailTemplate(string externalKey, string layoutHtmlAboveBodyTag, string layoutHtmlBelowBodyTag, Priority priority = Priority.Medium) { var layoutHtml = layoutHtmlAboveBodyTag + "<body>" + EmailContentHelper.GetContentAreaTag("dynamicArea") + "</body>" + layoutHtmlBelowBodyTag; using (var creator = new TemplatedEmailCreator(_config)) { return(creator.Create(externalKey, layoutHtml, priority)); } }
/// <summary> /// <para>Creates a Triggered Send Definition with an email template containing a content area and replacement value %Subject%.</para> /// <para>Use this if you want to edit the email markup in the ET UI. </para> /// </summary> /// <param name="externalKey"></param> /// <param name="priority"></param> /// <returns></returns> public int Create(string externalKey, Priority priority = Priority.Medium) { var layoutHtml = "<html>" + "<body>" + EmailContentHelper.GetContentAreaTag("dynamicArea") + EmailContentHelper.GetOpenTrackingTag() + EmailContentHelper.GetCompanyPhysicalMailingAddressTags() + "</body>" + "</html>"; using (var creator = new TemplatedEmailCreator(_config)) { return(creator.Create(externalKey, layoutHtml, priority)); } }