Copied to clipboard

Flag this post as spam?

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


  • Stefan 39 posts 70 karma points
    Feb 19, 2015 @ 12:16
    Stefan
    0

    Getting URL with media picker

    Im running umbraco on web matrix.

    I have added a propety to a document type. Its a media picker with the name powerpointPresentationLink

    In my template I have added @Currentpage.powerpointPresentationLink.

    The problem is that it doesnt display the link to the file , E.g localhost.folder.nameofpresentation.pptx.

    It displays up until the folder. Is they any way to get it to show the full url?

  • Tony Groome 261 posts 803 karma points
    Feb 19, 2015 @ 12:22
    Tony Groome
    0

    Hi Stefan

    I think you need something like @CurrentPage.Url to get the url. Hope this helps. :)

    Tony

  • Stefan 39 posts 70 karma points
    Feb 19, 2015 @ 12:30
    Stefan
    0

    Iv tired @Currentpage.powerpointPresentationLink.Url and @Currentpage.Url.powerpointPresentationLink . None work.

  • Dave Woestenborghs 3325 posts 11170 karma points MVP 5x admin c-trib
    Feb 19, 2015 @ 12:30
    Dave Woestenborghs
    1

    I think you need @CurrentPage.powerpointPresentationLink.umbracoFile

    Dave

  • Stefan 39 posts 70 karma points
    Feb 19, 2015 @ 12:37
    Stefan
    0

    Iv just put that in and get the whol page fails - 

    'int' does not contain a definition for 'umbracoFile'

     

    This is a snipit of the code :

     

    <!-- Any section element inside of this container is displayed as a slide -->

    <div class="slides">

    <!-- Starter Slide Start -->

    <section data-transition="linear" data-background="#ffffff" data-background-transition="slide" >

    <p><img width=312 height=144 src=http://www.studynet1.herts.ac.uk/web/ltic//Law_Libraries/logo.png border="none"> </p>

    <font color=black>

    <small><b>@CurrentPage.moduleTitle<br>

    @CurrentPage.Name<br>

    Lecture No @CurrentPage.lectureNumber - @CurrentPage.moduleCode</b></small><br>

     

    <p>

    <small>www.herts.ac.uk/law</small><br>

    <small>Please ensure that you have updated your browser to the latest version.<br>

    <a href=https://www.google.com/intl/en/chrome/browser/ target="_blank"><u>Google Chrome</u></a> or <a href=http://www.mozilla.org/en-US/firefox/all/ target="_blank"><u>Firefox</u></a> are the recommended browsers.<br><br>

    Press the right arrow key to continue or press the buttons located <br>

    at the bottom right of the screen to move between the slides.<br><br>

    Each slide has an accompanying audio file used to provide a narration of the content. 

    <br><i><br>You will need to press the play button on the audio bar.</i></small>

    <a [email protected]><small>Click here if you would like to download the original PowerPoint file</small></a>

    </p>

    </font><br>

    <div id='narration'><p align=middle>

    @CurrentPage.slideMP3 

     

    </div>

  • Dave Woestenborghs 3325 posts 11170 karma points MVP 5x admin c-trib
    Feb 19, 2015 @ 12:39
    Dave Woestenborghs
    102

    Can you try this @Umbraco.Media(CurrentPage.powerpointPresentationLink).umbracoFile

    Dave

  • Stefan 39 posts 70 karma points
    Feb 19, 2015 @ 12:41
    Stefan
    0

    Thanks . That fixed it !

  • This forum is in read-only mode while we transition to the new forum.

    You can continue this topic on the new forum by tapping the "Continue discussion" link below.

Please Sign in or register to post replies