Copied to clipboard

Flag this post as spam?

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


  • Sherry Ann Hernandez 320 posts 344 karma points
    Dec 07, 2010 @ 14:24
    Sherry Ann Hernandez
    0

    How to get the thumb image generated by umbraco

    Is there a way for me to use the generated thumb image instead of the actual image? Because I wanted to use this thumbsize in gallery and use the actual image size when the user clicks it.

  • Anthony Dang 1404 posts 2558 karma points MVP 3x c-trib
    Dec 07, 2010 @ 14:39
    Anthony Dang
    0

    If know you the url of the main image, just add _thumb to the filename.

    For example, if your url is /media/123/myImage.jpg, then the thumbnail url will be  /media/123/myImage_thumb.jpg

  • Kim Andersen 1447 posts 2196 karma points MVP
    Dec 07, 2010 @ 14:47
    Kim Andersen
    0

    Another approach is to use the great ImageGen package. With this package you can specify exactly which size you want your images to be. So if the generated thumbnail size doesn't quite fit your size, then you can use just sepcify how wide og high you want your images to be.

    It's a great package, and besides that it's very easy to use. Up to you :)

    /Kim A

  • Sherry Ann Hernandez 320 posts 344 karma points
    Dec 08, 2010 @ 06:31
    Sherry Ann Hernandez
    0

    @Anthony

    But I usually get the image url using the umbraco media library. I was thinking if there is a extension wherein I can pull up the thumb image file.

  • Chriztian Steinmeier 2800 posts 8790 karma points MVP 8x admin c-trib
    Dec 08, 2010 @ 09:08
    Chriztian Steinmeier
    0

    Hi Sherry,

    You can do a little string-manipulation to get the thumbnail image:

    <img src="{substring-before($mediaNode/umbracoFile, concat('.', $mediaNode/umbracoExtension))}_thumb.{$mediaNode/umbracoExtension}" />

    /Chriztian

Please Sign in or register to post replies

Write your reply to:

Draft