What the "just add Media type aliases" means, is if you've created a PDFFile media type or a WordDoc media type, and you want to process those like the others, then you should add those aliases to the apply-templates line and the item template, like this:
just add Media type aliases
<?xml version="1.0" encoding="utf-8" ?> <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:umb="urn:umbraco.library" exclude-result-prefixes="umb" > <xsl:output method="xml" indent="yes" omit-xml-declaration="yes" /> <xsl:param name="currentPage" /> <xsl:variable name="mediaFolder" select="/macro/mediaFolder" /> <xsl:template match="/"> <xsl:if test="$mediaFolder[Folder]"> <xsl:variable name="media" select="umb:GetMedia($mediaFolder/Folder/@id, true())" /> <!-- If no errors, this will run the Folder template below --> <xsl:apply-templates select="$media[not(error)]" /> </xsl:if> </xsl:template> <!-- Template for the folder --> <xsl:template match="Folder"> <ul class="client-logo"> <!-- Run templates for individual items (just add Media type aliases) --> <xsl:apply-templates select="File | Image" /> </ul> </xsl:template> <!-- Template for items - you can create individual templates to render them differently --> <xsl:template match="File | Image"> <li><img alt="{imageAltTag}" src="{umbracoFile}"/></li> </xsl:template> </xsl:stylesheet>Hi René,
I recognize my code from miles away :-)
What the "just add Media type aliases" means, is if you've created a PDFFile media type or a WordDoc media type, and you want to process those like the others, then you should add those aliases to the apply-templates line and the item template, like this:
<xsl:apply-templates select="File | Image | PDFFile | WordDoc" /> ... <xsl:template match="File | Image | PDFFile | WordDoc"> ... </xsl:template>Hope this clears up some confusion, otherwise don't hesitate to ask again.
/Chriztian
HI
Yes it is your own code..
Well - that's what you meant, tanks.
René
is working on a reply...
This forum is in read-only mode while we transition to the new forum.
You can continue this topic on the new forum by tapping the "Continue discussion" link below.