Copied to clipboard

Flag this post as spam?

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


  • ed beltran 2 posts 22 karma points
    May 27, 2014 @ 18:05
    ed beltran
    0

    Media Item Propreties

    I am trying to get the values (dimension) of a media item for the images within my partial view.

    Using Umbraco 7.

    Code:

    @inherits Umbraco.Web.Mvc.UmbracoTemplatePage

    <img src="@Umbraco.TypedMedia(Model.Content.GetPropertyValue("ctaImage")).Url" alt="@Model.Content.GetPropertyValue("ctaTitle")" height="" border="0" width="">

  • Jeavon Leopold 3074 posts 13632 karma points MVP 11x admin c-trib
    May 27, 2014 @ 21:46
    Jeavon Leopold
    0

    Hi Ed,

    Are you using the default "Image" media type or a custom media type?

    Jeavon

Please Sign in or register to post replies

Write your reply to:

Draft