Umbraco的轮廓带有工作流程选项,可让您在用户提交表单后应用XSLT文件发送电子邮件。XSLT为轮廓中的umbraco表单创建超链接
它配备了此示例:
<?xml version="1.0" encoding="utf-8"?>
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:msxsl="urn:schemas-microsoft-com:xslt"
xmlns:user="urn:my-scripts"
xmlns:umbraco.library="urn:umbraco.library"
exclude-result-prefixes="xsl msxsl user umbraco.library">
<xsl:output method="html" media-type="text/html" doctype-public="-//W3C//DTD XHTML 1.0 Strict//EN"
doctype-system="DTD/xhtml1-strict.dtd"
cdata-section-elements="script style"
indent="yes"
encoding="utf-8"/>
<xsl:param name="records" />
<xsl:template match="/">
<h3>Intro</h3>
<p>
Hello, this is a sample email using xslt to convert a record into a custom email
</p>
<h3>the fields</h3>
<ul>
<xsl:for-each select="$records//fields/child::*">
<li>
<h4>
Caption: <xsl:value-of select="./caption"/>
</h4>
<p>
<xsl:value-of select=".//value"/>
</p>
</li>
</xsl:for-each>
</ul>
<h3>The actual xml</h3>
<xsl:copy-of select="$records"/>
</xsl:template>
</xsl:stylesheet>
一个表单字段是文件上传字段简历
理想我想,如果我能输出正确的链路喜欢它。
字段名称是“上传简历”,目前这样的事情是被输出只需在发送电子邮件文本:
“/一把umbraco /插件/ umbracoContour /文件/ e105a66a-7478-4f95- 95ad-d4da3190c6ce/d9e0087e-733B-4b4d-9b54-41d4aa979c11/mycv.pdf”
我怎么可以重新夹具这个XSLT,这样,当它遇到‘上传简历’字段它创建一个链接,而不仅仅是原始文本。
在href超链接将最终被类似:
“http://www.example.com/umbraco/plugins/umbracoContour/files/e105a66a-7478-4f95-95ad-d4da3190c6ce/d9e0087e “-733b-4b4d-9b54-41d4aa979c11/mycv.pdf”
您忘了提供源XML文档(请尽可能小)。要编写或修改转换,需要源XML文档和预期结果(以及转换必须实现的需求描述)。请编辑问题并提供这些信息。 –