2 users online. Create an account or sign in to join them.Users
{values}
This is an open discussion with 4 replies, filed under General.
Search
{title/@handle} will refer to the "handle" attribute of the "title" node in your page's XML, which you would have added to the page via Symphony's data source editor and page.
Think of it similar to
<value-of select="something" />
If you wanted to use that in an attribute href you'd have to do it like
<a>
<xsl:attribute name="href">
<xsl:value-of select="something" />
</xsl:attribute>
</a>
That's unnecessarily complex and annoying. Instead, you can use the shorthand notation like
<a href="{something}" />
The $-prefix just separates parameters from nodes. {$root} is eqivalent to <xsl:value-of select="$root" /> and {title/@handle} is equivalent to <xsl:value-of select="title/@handle" />
The use of curly braces inside element attributes is called Attribute Value Template, or AVT.
I think he's confused by the @, which means it's targeting an attribute. xxxx in this example XML.
<products>
<title handle="xxxx">Xx xx</title>
</products>
Should you not use the @ in your example, it would look for a new node, handle, inside title instead.
Create an account or sign in to comment.
Hello, I read {$param} is from the parameters pool, but what does a string like this point at?
<a href="{$root}/products/{title/@handle}/">(ignore the $root of course)
Thanks!