Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Anthony Candaele 1197 posts 2049 karma points
    Jul 23, 2011 @ 15:01
    Anthony Candaele
    0

    ImageGen not working with macro parameter

    Hi,

    I have a .Xslt file 'screenshot.xslt' where I want to rezise an image using ImageGen.

    my code looks like this:

    <xsl:variable name="image" select="/macro/image/Image/umbracoFile" />

    <xsl:if test="string-length($image) &gt; 0">
      <id="single_image" href="{$image}" title="{$title}"><img src="ImageGen.ashx?image={$image}" width="200" /></a>   
    </xsl:if>

    for some reason this does not work. If I delete the ImageGen code like this:

    <xsl:if test="string-length($image) &gt; 0">
      <id="single_image" href="{$image}" title="{$title}"><img src="{$image}" width="200" /></a>   
    </xsl:if>

    the thumbnail image is shown in the page. 

    Does anyone has an idea why ImageGen doesn't work with this macro parameter?

    Thanks for your help,

    Anthony



  • Kim Andersen 1447 posts 2197 karma points MVP
    Jul 23, 2011 @ 15:39
    Kim Andersen
    1

    Hi Anthony

    I think you're not giving the right path to the ImageGen.ashx-file. I think you need the slash in front of the path like this:

    <img src="/ImageGen.ashx?image={$image}&amp;width=200" width="200" />

    /Kim A

  • Anthony Candaele 1197 posts 2049 karma points
    Jul 23, 2011 @ 16:13
    Anthony Candaele
    0

    Hi Kim,

    You're right. Thanks a lot. I'm currently editing the Umbraco Cms pages on my website: http://www.webmove.be/startpagina/umbracocms

    The screenshot.xslt is for showing the screenshot pictures in the right column as you can see on subsequent pages:

    http://www.webmove.be/startpagina/umbracocms/versiebeheer

    http://www.webmove.be/startpagina/umbracocms/meertaligheid

    and http://www.webmove.be/startpagina/umbracocms/veiligheid

    I don't want to take full credit for this layout, as I was inspired a lot by : http://www.webs.be/diensten/webdevelopment/cms.aspx :)

    greetings,

    Anthony

  • Kim Andersen 1447 posts 2197 karma points MVP
    Jul 23, 2011 @ 17:48
    Kim Andersen
    0

    Ahh yeah, I can see where you are using it :)

    And you are welcome Anthony - anytime ;)

    /Kim A

  • 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.

Please Sign in or register to post replies