Copied to clipboard

Flag this post as spam?

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


  • Kim hansen 1 post 71 karma points
    Jan 16, 2017 @ 18:33
    Kim hansen
    0

    Why Developer get node reference like this way in Umbraco?

    I have seen in umbraco code, where developers get reference to a content page, like this:

    var content = UmbracoContext.PublishedContentRequest.IsInternalRedirectPublishedContent ? ubracoContext.PublishedContentRequest.InitialPublishedContent : UmbracoContext.PublishedContentRequest.PublishedContent;

    BUT why do they do that ?

    Why not use @ Model.Content ()

    What is (What do they do):

    IsInternalRedirectPublishedContent?

    InitialPublishedContent ?

    PublishedContent ?

  • Alex Skrypnyk 6182 posts 24283 karma points MVP 8x admin c-trib
    Jan 23, 2017 @ 22:17
    Alex Skrypnyk
    0

    Hi Kim,

    Where did you see this code?

    It looks like code which work when user uses internal redirect.

    Thanks,

    Alex

  • Alex Skrypnyk 6182 posts 24283 karma points MVP 8x admin c-trib
    Jan 29, 2017 @ 21:41
    Alex Skrypnyk
    0

    Hi Kim

    Did you solve the problem?

    Can you share with us how did you solve ?

    Thanks,

    Alex

  • 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