I'm facing a problem with a multilingual site that I made. When I'm changing language, from greek to english in my example, there are some elements that are missing although that they are using the same XSLT. For example Some images are loaded in the greek version but in the english one are not.To be more precise, my code is
<xsl:variable name="gallery" select="number($currentPage/gallery)" /> <xsl:variable name="thumbWidth" select="number(256)" /> <xsl:variable name="thumbHeight" select="number(170)" /> <xsl:template match="/"> <!-- Displays all images from a folder in the Media Library --> <xsl:if test="number($gallery)"> <xsl:for-each select="umbraco.library:GetMedia($gallery, true())/Image"> <xsl:if test="umbracoFile !=''"> { src: '<xsl:value-of select="umbracoFile"/>', dir: 'up' }, </xsl:if> </xsl:for-each> { src: '/media/1533/santorini3.jpg', dir: 'down' } </xsl:if> </xsl:template>
kind regards
Apostolis
P.S. I'm not so experienced in Umbracco so any help would be great
How have you setup your content structure in Umbraco? Does it look something like this
Home (GB) page page page Home (Greek) page page page
Then it's 1-1 and then you should of course make sure that there has at all been selected any images on the different pages where something might seem to be missing.
At a first glance I don't think the issue has to do with the code itself but a bit more information about how you have structured the site would be nice :)
XSLT - GetMedia
Hi to everyone,
I'm facing a problem with a multilingual site that I made. When I'm changing language, from greek to english in my example, there are some elements that are missing although that they are using the same XSLT. For example Some images are loaded in the greek version but in the english one are not.To be more precise, my code is
<xsl:variable name="gallery" select="number($currentPage/gallery)" />
<xsl:variable name="thumbWidth" select="number(256)" />
<xsl:variable name="thumbHeight" select="number(170)" />
<xsl:template match="/">
<!-- Displays all images from a folder in the Media Library -->
<xsl:if test="number($gallery)">
<xsl:for-each select="umbraco.library:GetMedia($gallery, true())/Image">
<xsl:if test="umbracoFile !=''">
{ src: '<xsl:value-of select="umbracoFile"/>', dir: 'up' },
</xsl:if>
</xsl:for-each>
{ src: '/media/1533/santorini3.jpg', dir: 'down' }
</xsl:if>
</xsl:template>
kind regards
Apostolis
P.S. I'm not so experienced in Umbracco so any help would be great
Hi Apostolis
How have you setup your content structure in Umbraco? Does it look something like this
Home (GB)
page
page
page
Home (Greek)
page
page
page
Then it's 1-1 and then you should of course make sure that there has at all been selected any images on the different pages where something might seem to be missing.
At a first glance I don't think the issue has to do with the code itself but a bit more information about how you have structured the site would be nice :)
/Jan
is working on a reply...