使用表单上的复选框输入将表单数据发送到不同的电子邮件地址
我正在为客户构建一个表单。这是概要。该表格将用作让工作人员联系填写表格的人的请求。但是,有一份工作人员名单,将根据主题内容与他们联系。因此,我想在表单上创建一个复选框输入部分,并将每个员工的电子邮件地址附加到相应的复选框。因此,填写表格的人只能检查满足其需要的员工。最后,当该人点击“提交”时,该表格将仅通过电子邮件发送给在表格中勾选的工作人员。我不知道如何设置它。
I am building a form for a client. Here is the rundown. The form will be used as a request to have a staff member contact the person filling out the form. However, there is a list of staff members that will contact them depending on what the subject matter is. So, I want to create a checkbox input section on the form with each staff person's email address attached to a corresponding checkbox. So, the person filling out the form can check only the staff people necessary for their needs. Finally, when the person clicks "submit", the form will be emailed to only the staff members who were checked in the form. I'm at a loss of how to set this up.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
在 JavaScript 中,您可以从“员工”对象(姓名、电子邮件地址等)数组创建一组复选框。
我需要了解有关您的设置的更多信息,但如果您想在前端使用 JavaScript 在 Java 中执行此操作(如您的标签所示),我会这样做:
同样,这是一个非常简单的示例,说明了如何执行此操作。有一百万种方法。我希望这会有所帮助,但请随意举更多例子,我可能会更具体。
In JavaScript, you can create a group of checkboxes from an array of "staff member" objects (names, email addresses, etc.).
I'd need to know more about your setup, but if you wanted to do this in Java with JavaScript on the front end (as your tags suggest), here's what I'd do:
Again, this is a really simple example of how to do this. There are a million ways. I hope this helps, but feel free to give more examples and I can probably be more specific.