Copied to clipboard

Flag this post as spam?

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


  • bev0 39 posts 59 karma points
    Mar 03, 2010 @ 22:10
    bev0
    0

    return image actual content

    hi all,

    i was wondering if it is possible for umbraco to return the actual content of an image, let's say: x.jpg.

    when user go to a page like http://umbraco.org/x.aspx, he/she will see an image in the browser and if he/she download it, its content type is also a "image/jpg". because x.aspx is really an image (x.jpg).

    please help,
    bev0

  • Chriztian Steinmeier 2800 posts 8791 karma points MVP 8x admin c-trib
    Mar 03, 2010 @ 22:47
    Chriztian Steinmeier
    0

    HI bev0,

    Without knowing anything about it, I'd think you need to do two things:

    1. Change the ContentType of the response, which you can do with a server tag: 

    <umbraco:ContentType runat="server" MimeType="image/jpg"></umbraco:ContentType>

    2. Output the binary data, which you'll have to find out yourself - XSLT is probably not what you want here...

    /Chriztian

Please Sign in or register to post replies

Write your reply to:

Draft