Copied to clipboard

Flag this post as spam?

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


  • syn-rg 282 posts 425 karma points
    Apr 14, 2011 @ 02:45
    syn-rg
    0

    Get more image file infomation on upload?

    Currently the Image Media Type can get the width, height, size and type of file uploaded.
    Using umbracoWidth, umbracoHeight, umbracoBytes and umbracoExtension.

    Is it possible to extend this further to get the following information from the image:

    • Color mode (CMYK, RGB, Grayscale, etc)
    • Resolution (72, 150, 300 dpi)
    • Date created
    • Date modified
    • Profile name (Cinema HD, Adobe RGB, etc).
    • File name

    Can anybody suggest a method of achieving this?

    Cheers,
    JV

     

  • Daniel Bardi 927 posts 2562 karma points
    Apr 14, 2011 @ 07:02
    Daniel Bardi
    0

    Create a class that inherits from ApplicationBase.

    In the constructor, you can attach to the Media Create event and get a handle on the file via the umbracoFile property. (using Server.MapPath)

    From there you can get what you want from the image

  • Ove Andersen 435 posts 1541 karma points c-trib
    Apr 14, 2011 @ 09:04
    Ove Andersen
    0

    Take a look at the PhotoMetaData package by Sebastiaan Janssen:

    http://our.umbraco.org/projects/website-utilities/cultiv-photometadata

    It should do what you are looking for.

Please Sign in or register to post replies

Write your reply to:

Draft