Press Ctrl / CMD + C to copy this to your clipboard.
This post will be reported to the moderators as potential spam to be looked at
hi,
i'm working with umbraco 4.7 and i'm trying to show a image. I use the next code but don't show the image. Anybody knows why?
My xslt:
<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE xsl:Stylesheet [ <!ENTITY nbsp " "> ]><xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:msxml="urn:schemas-microsoft-com:xslt" xmlns:umbraco.library="urn:umbraco.library" exclude-result-prefixes="msxml umbraco.library">
<xsl:output method="xml" omit-xml-declaration="yes"/>
<xsl:param name="currentPage"/>
<xsl:variable name="mediaPropName" select="/macro/imagen" />
<xsl:template match="/">
<xsl:variable name="media" select="umbraco.library:GetMedia($currentPage/@alias=$mediaPropName, 0) " /><img src="{$media/umbracoFile}" alt="{$media/altText}" />
</xsl:template>
</xsl:stylesheet>
Thanks
Are you using the Digibiz Advanced Media Picker to select your media? If you do you can use this sample.
Jeroen
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.
Continue discussion
how get a Media with Umbraco 4.7
hi,
i'm working with umbraco 4.7 and i'm trying to show a image. I use the next code but don't show the image. Anybody knows why?
My xslt:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE xsl:Stylesheet [ <!ENTITY nbsp " "> ]>
<xsl:stylesheet
version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:msxml="urn:schemas-microsoft-com:xslt"
xmlns:umbraco.library="urn:umbraco.library"
exclude-result-prefixes="msxml umbraco.library">
<xsl:output method="xml" omit-xml-declaration="yes"/>
<xsl:param name="currentPage"/>
<xsl:variable name="mediaPropName" select="/macro/imagen" />
<xsl:template match="/">
<xsl:variable name="media" select="umbraco.library:GetMedia($currentPage/@alias=$mediaPropName, 0) " />
<img src="{$media/umbracoFile}" alt="{$media/altText}" />
</xsl:template>
</xsl:stylesheet>
Thanks
Are you using the Digibiz Advanced Media Picker to select your media? If you do you can use this sample.
Jeroen
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.