简体   繁体   English

根据“营销人员Web表单”中的下拉列表选择将电子邮件路由到特定电子邮件地址

[英]Route an email to specific email address depending on dropdown selection in Web Form for Marketers

What would be the best way in Web Forms for Marketers to look at a dropdown selection and determine where to route an email depending on what the selection is. 在市场营销人员的Web窗体中查看下拉选择并根据选择内容确定将电子邮件路由到何处的最佳方法是什么。 Having multiple selections and either sending the email to sales or support depending on the selection 有多种选择,并根据选择将电子邮件发送给销售人员或支持人员

What you'd want to do is 您想要做的是

  1. Use the Send Email Message save action 使用发送电子邮件保存操作
  2. Invoke the processMessage pipeline in Sitecore.Forms.config and add a custom processor something like this: Sitecore.Forms.config中调用processMessage管道,并添加一个自定义处理器,如下所示:

     public void Process(ProcessMessageArgs args) { var field = args.Fields.GetEntryByName("myFieldName"); if (field == null) { return; } var selection = field.Value; // TODO: select the right e-mail according to selection's value var email = "the@mail.com"; // Append the email if (args.To.Length != 0) { args.To.Append(","); } args.To.Append(email); } 

You could tag the drop down value selected to the Analytics database (feature available in WFFM) then add all applicants to an engagement plan through a save action and, by using rules looking at the tagged value, route them through different actions sending separate emails. 您可以将选择的下拉值标记到Analytics(分析)数据库(WFFM中可用的功能),然后通过保存操作将所有申请人添加到参与计划中,并通过使用查看标记值的规则,通过发送单独电子邮件的不同操作来路由他们。 That is, if you want to avoid coding ;-) 也就是说,如果您想避免编码;-)

Have you looked into http://sdn.sitecore.net/upload/sdn5/products/web_forms2/web%20forms%20for%20marketers%20v2_3%20reference-usletter.pdf ? 您是否浏览过http://sdn.sitecore.net/upload/sdn5/products/web_forms2/web%20forms%20for%20marketers%20v2_3%20reference-usletter.pdf In section 2.6 it talks of the submit actions which includes sending emails, and you will have access to the submitted info in the action as well. 在2.6节中,它讨论了包括发送电子邮件在内的提交动作,您也可以在该动作中访问提交的信息。

You can always write a custom action else. 您始终可以编写其他自定义操作。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM