Hi!
The one thing I noticed with your code is that you do not have ' around the alias names. Try that, like this:
instead of:
Also, you might consider using xsl:choose instead of multiple xsl:if. The english meta data would be placed in the xsl:otherwise option. See here: http://www.w3schools.com/Xsl/el_choose.asp
Thank you for the quick reply and for the solution to my problem. I'm still a newbie in XSLT, only started using it in connection with Umbraco :)
and thanks for recommending xsl:choose instead of xsl:if, it really made my XSLT much simpler.
Meta data
Hi experts
I'm trying to make an umbraco macro that pulls meta data from my content pages dynamically.
It looks like this:
]>
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:msxml="urn:schemas-microsoft-com:xslt"
xmlns:umbraco.library="urn:umbraco.library"
xmlns:softpilar.library="urn:softpilar.library"
exclude-result-prefixes="msxml umbraco.library softpilar.library">
However I cant get it to work when I place the macro in my template / master page. The meta data display empty in my content pages:
Help is very appreciated. Thanks in advance.
Hi!
The one thing I noticed with your code is that you do not have ' around the alias names. Try that, like this:
instead of:
Also, you might consider using xsl:choose instead of multiple xsl:if. The english meta data would be placed in the xsl:otherwise option. See here: http://www.w3schools.com/Xsl/el_choose.asp
Hi Daniel
Thank you for the quick reply and for the solution to my problem. I'm still a newbie in XSLT, only started using it in connection with Umbraco :)
and thanks for recommending xsl:choose instead of xsl:if, it really made my XSLT much simpler.
is working on a reply...