title: is it possible to use "attribute value templates" in variable or param?
body: <p>this is nice and short:</p>
  
  <pre class="lang-xml prettyprint-override"><code>&lt;img src="{$base}/{@filename}.jpg" /&gt;
  </code></pre>
  
  <p>but sometimes you need to reuse the <code>src</code>, so it turns into this:</p>
  
  <pre class="lang-xml prettyprint-override"><code>&lt;xsl:variable name="imgsrc"&gt;
      &lt;xsl:value-of select="$base"&gt;/&lt;xsl:value-of select="@filename"&gt;
      &lt;xsl:text&gt;.jpg&lt;/xsl:text&gt;
  &lt;/xsl:variable&gt;
  &lt;img src="$imgsrc" /&gt;
  </code></pre>
  
  <p>According to <a href="http://www.w3.org/TR/xslt#dt-attribute-value-template" rel="noreferrer">http://www.w3.org/TR/xslt#dt-attribute-value-template</a> you can't use the "curly brackets interpolation syntax" outside of literal element attributes, but there might be a not-so-hacky hack to do the trick? I'm lazy, I know.</p>