⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 short-attribute.xtp

📁 解压在c盘
💻 XTP
字号:
<s1 title="Attribute Value Templates"><p>Because calculating attributes is very common, the XSLT standardadds a special syntax for attribute value templates.A stylesheet can uses an attribute value template to calculatethe template value for the element directly.  Curly brackets introducea value-of expression, e.g. "{@class}".  The following stylesheetis a direct translation of the previous example.</p><example title='default.xsl'>&lt;xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform">&lt;xsl:template match="box">  &lt;table class="{@class}">    &lt;tr>      &lt;td>        &lt;xsl:apply-templates/>      &lt;/td>    &lt;/tr>  &lt;/table>&lt;/xsl:template>&lt;/xsl:stylesheet></example><p>The example XTP and its generated HTML is identical to the previous examplesince attribute value templates are just a syntactic shortcut.</p><example title='hello.xtp'><example>&lt;example>This is an example.&lt;/example></example><results>&lt;table class="example">&lt;tr>  &lt;td>This is an example&lt;/td>&lt;/tr>&lt;/table></results></example><s2 title="Summary"><ul><li><var/"{...}"/> interpolates an attribute's value.</ul></s2></s1>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -