Copied to clipboard

Flag this post as spam?

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


  • Sam 47 posts 153 karma points
    Feb 24, 2014 @ 23:14
    Sam
    0

    Thoughts on How to Set Up Member Photos?

    We have a website I'm converting from classic ASP and am trying to put into Umbraco. The key feature of the website is for members to be able to upload photos.

    For starters, I'm torn as to whether I should do the photos as a Media node or a Content node with a link to the image's location on disk?

    Members submit a description, category, and brand with their photos. Categories and brands are represented as nodes in my content tree. So I need to figure out the best way to represent those to the members as well. I'm thinking of doing it as a drop down with indented category names as the text and the node id as the value.

    I'm not sure what the best way is to link the photo with the member? Umbraco separated the users from the members so I'm assuming I don't pass the member id when creating the node. Create a custom field to store it?

    Is there a way to associate the photos with the member in the admin? I'd want to do this if somebody uploaded a bunch of garbage. It would be easier to find/delete them by just going through the member's photos.

  • Matt Linsenbardt 24 posts 147 karma points
    Feb 25, 2014 @ 16:36
    Matt Linsenbardt
    0

    Hi Sam,

    You can create a custom Media Type, e.g. Member Photo with a requred field of Member Id. When creating documents of this type via the API, simply pass in the currently logged in Member Id for this new field.

  • Sam 47 posts 153 karma points
    Feb 25, 2014 @ 16:38
    Sam
    0

    Thanks Matt, that is one of the options. I'm curious if there is then a way to display all of the photos for a specific member in the backend?

  • David Brendel 792 posts 2970 karma points MVP 3x c-trib
    Feb 25, 2014 @ 16:38
    David Brendel
    0

    Hi Sam,

    also you can add a new property to your member type called avatar (or something similar) of type MediaPicker. Then you can create the media item when they upload the picture and save its id on the member property. So you also can see it in the umbraco backoffice.

    Or you can link the media item and the member with the relations api.

    Regards, David

  • Sam 47 posts 153 karma points
    Feb 25, 2014 @ 16:40
    Sam
    0

    Thanks David. I thought about that, but users can upload more than one image.

    Relations API, that's a new one I haven't heard of. Will check it out.

  • Matt Linsenbardt 24 posts 147 karma points
    Feb 25, 2014 @ 16:42
    Matt Linsenbardt
    0

    The relations API looks like the winning ticket. You will likely have to create a custom dashboard or section in the back office to select all media by member id.

    Umbraco Relations API
    http://umbraco.com/follow-us/blog-archive/2012/12/7/getting-to-know-umbraco-relations.aspx

     

Please Sign in or register to post replies

Write your reply to:

Draft