I'm trying to create a dynamic gallery with xslt and have searched the forums but can't seem to find any threads with the same problem. The idea is that users can select up to 6 pictures from the media tab on the individual content pages so that there can be different galleries on different pages. The file saves correctly, and I'm not receiving any errors, but when the page loads nothing is displayed.
The xslt
<xsl:if test="$currentPage/image > 0">
<xsl:variable name="gal1" select="umbraco.library:GetMedia($currentPage/galimg1, false())" />
<xsl:variable name="gal2" select="umbraco.library:GetMedia($currentPage/galimg2, false())" />
<xsl:variable name="gal3" select="umbraco.library:GetMedia($currentPage/galimg3, false())" />
<xsl:variable name="gal4" select="umbraco.library:GetMedia($currentPage/galimg4, false())" />
<xsl:variable name="gal5" select="umbraco.library:GetMedia($currentPage/galimg5, false())" />
<xsl:variable name="gal6" select="umbraco.library:GetMedia($currentPage/galimg6, false())" />
<xsl:if test="not($gal1/error)">
<xsl:variable name="url" select="$gal1/umbracoFile" />
<a rel="prettyPhoto [gallery]" href="{$url}">
<img src="{$url}" />
</a>
</xsl:if>
<xsl:if test="not($gal2/error)">
<xsl:variable name="url" select="$gal2/umbracoFile" />
<a rel="prettyPhoto [gallery]" href="{$url}">
<img src="{$url}" />
</a>
</xsl:if>
<xsl:if test="not($gal3/error)">
<xsl:variable name="url" select="$gal3/umbracoFile" />
<a rel="prettyPhoto [gallery]" href="{$url}">
<img src="{$url}" />
</a>
</xsl:if>
<xsl:if test="not($gal4/error)">
<xsl:variable name="url" select="$gal4/umbracoFile" />
<a rel="prettyPhoto [gallery]" href="{$url}">
<img src="{$url}" />
</a>
</xsl:if>
<xsl:if test="not($gal5/error)">
<xsl:variable name="url" select="$gal5/umbracoFile" />
<a rel="prettyPhoto [gallery]" href="{$url}">
<img src="{$url}" />
</a>
</xsl:if>
<xsl:if test="not($gal6/error)">
<xsl:variable name="url" select="$gal6/umbracoFile" />
<a rel="prettyPhoto [gallery]" href="{$url}">
<img src="{$url}" />
</a>
</xsl:if>
</xsl:if>