Copied to clipboard

Flag this post as spam?

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


  • Mark Evans 86 posts 116 karma points
    Sep 26, 2014 @ 14:47
    Mark Evans
    0

    linking to a document

    im trying to link to a pdf file thats asscoaited with a page... the file is in the media area....

    whereas a url link ie part of the page property is like this - <a href="@Model.Content.GetPropertyValue("link")" target="@linkTarget">

    i cant seem to access a media file link

     

     

  • Jeavon Leopold 3072 posts 13628 karma points MVP 10x admin c-trib
    Sep 26, 2014 @ 14:51
    Jeavon Leopold
    0

    I think you are looking for something like this?

    <a href="@Umbraco.TypedMedia(Model.Content.GetPropertyValue("link")).Url" target="@linkTarget">
    
  • Mark Evans 86 posts 116 karma points
    Sep 26, 2014 @ 15:10
    Mark Evans
    0

    great thanks. i was looking for getmedia, maybe found an old link

  • Jeavon Leopold 3072 posts 13628 karma points MVP 10x admin c-trib
    Sep 26, 2014 @ 15:12
    Jeavon Leopold
    0

    Np, UmbracoHelper is documented here

Please Sign in or register to post replies

Write your reply to:

Draft