I am using the DAMP media picker in my umbraco installation and it works great.
I have the following XSLT at the moment to display an image that has been uploaded and 'picked' using the plugin.
Can anybody point me in the right direction as to how I can check to see if this image property has a value (i.e. an image has been chosen) so that I can hide the image element if not?
Check if Image is Empty
Hi,
I am using the DAMP media picker in my umbraco installation and it works great.
I have the following XSLT at the moment to display an image that has been uploaded and 'picked' using the plugin.
Can anybody point me in the right direction as to how I can check to see if this image property has a value (i.e. an image has been chosen) so that I can hide the image element if not?
Many thanks guys!
<xsl:param name="currentPage"/>
<xsl:template match="/">
<img src="{$currentPage/umbCategoryHeaderImage/DAMP[@fullMedia]/mediaItem/Image/umbracoFile}" />
</xsl:template>
</xsl:stylesheet
<xsl:if test="$currentPage/umbCategoryHeaderImage/DAMP[@fullMedia]/mediaItem/Image != ''">
<img src="{$currentPage/umbCategoryHeaderImage/DAMP[@fullMedia]/mediaItem/Image/umbracoFile}" />
</xsl:if>
is working on a reply...