邮件链接共享点设计器
在共享点设计器中,我有一个控件
<SharePointWebControls:TextField FieldName="Title" runat="server"></SharePointWebControls:TextField>
,我想要一个 mailto 链接 这将使用此标题作为电子邮件的主题,并且我需要电子邮件正文包含一些文本,例如“我的示例文本”,
我该怎么做?
谢谢
In sharepoint designer I have a control
<SharePointWebControls:TextField FieldName="Title" runat="server"></SharePointWebControls:TextField>
I want to have a mailto link
that will use this title as the subject of the email and i need the body of the email to contain some text e.g. "My Example Text"
how do i do this?
thanks
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
在我看来,您正在寻找的不是 MailTo 链接,而是联系表单,可能类似于 这个示例 很有用,至少可以作为参考。 另外,此 Sharepoint 联系表单示例也值得一看。
It sounds to me as though, rather than a MailTo link you are looking for a contact form, perhaps something like this example would be useful, at least as something to look at. Also this Sharepoint contact form example could be worth a look.
我会使用上面给出的方法。
Jason 给出的评论具有误导性 - 该代码实际上是自定义字段控件。 是的,我猜自定义字段控件可以称为用户控件,因为它们是用 C# 编写的。
我在自己的解决方案中使用类似的自定义字段控件。
I would use the above given approach.
The comment Jason gave is misleading - that code is in fact a custom field control. And yes, I guess custom field controls could be called user controls, since they are written in C#.
I use similar custom field controls in my own solutions.
我建议创建一个自定义字段类,它继承自 TextField 并在显示模式下创建 mailto 标记。
然后只需将其添加为安全控件,并在如下代码中使用它:
希望有帮助
I would suggest creating a custom field class, that inherits from TextField and in the display mode creates the mailto tag.
And then just add it as a safe control, and use it in code like this:
Hope it helps